Mensen/ept_TFCE-matlab

Unbalanced Designs

Closed this issue · 3 comments

Hi -
I've been delighted so far with the TFCE toolbox and I was just wanted to run something by you to make sure that it is valid.

I know that the ept_TFCE_ANOVA only works on balanced designs the way it is setup now. That was an issue for me because I've got two lesion groups and controls and I wasn't able to record an equal number of lesion patients. I dug around and found FMUT (https://github.com/ericcfields/FMUT) which is a branch/extension of the Mass Univariate Toolbox. FMUT has implemented cluster permutation for between group and within group unbalanced designs. I took the FMUT permutation function, which returns an F-distribution (nPermXchanXtime for each factor) and than rather than run the cluster-mass identification on the factor F-distributions, I ran each nPerm through the ept_mex_TFCE2D. Essentially it is the same thing that you do in ept_TFCE_ANOVA, except it builds a permuted F distribution first (which is slower) and then locates clusters. In ept_TFCE_ANOVA you return an F_Perm for each permutation and in that same loop run ept_mex_TFCE2D on it.

Am I crazy? The values I get back aren't insane and are in keeping with what I find using FMUT itself and reflect what the data looks like... Just wanted to check.

Also many thanks for the toolbox and your PhD Thesis which was actually an enjoyable read. Great piece of work.
J

That all sounds completely reasonable.

I often do things like this by myself as well. Just replace the T-test, or ANOVAs with some other statistical calculation and then run the TFCE on those values etc. The only reason the balanced requirement is in the toolbox still is because its the only implementation I've found to be relatively fast enough to run in a non-frustrating amount of time.

How long does your analysis take using the FMUT function? Perhaps I should check it out.

I've generally been relying on mixed models now to do all my statistics so I can include as many factors as I like along with some more odd mixed designs for experiments... but the whole analysis often now takes hours to complete because of this. So didn't want to make that so publicly available since a lot can go wrong in your design (and in the worst case, not cause an error and still produce results that look believable).

Great tip!

I'll look into it for sure.