repeated measure anova two options
Show older comments
Hello,
I am trying to use repeated measure ANOVA “ranova” in MATLAB. According to MATLAB tutorial, there are two option: 1: ranova(rm) and 2: ranova(rm,'WithinModel',WM).
I tried both and they give different results for the within model analysis (in my example the within model variable is time; I have repeated measurements). Option 1 has a closer results to those produced by other software like R; however, it does not give me the between model results which are the main effect of between model variables and their interactions. I appreciate it if you let me know what the difference is.
Also, the sums of squares are not the same as what I get from R. Could you please help me find out about this discrepancy?
Best,
Sepideh.
Answers (1)
Jeff Miller
on 15 Dec 2020
Not sure but I think you need
T = table([1 2]','VariableNames',{'Time'});
T.Time = categorical(T.Time); % add this line
Maybe post one of your 't' data tables so the design is clearer?
3 Comments
Sophi Af
on 23 Dec 2020
Jeff Miller
on 24 Dec 2020
If each line of your t table represents a different person, then you should use the ranova command including 'WithinModel'.
Sophi Af
on 24 Dec 2020
Categories
Find more on Mathematics in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!