Multcompare for fitlm output or something similar?
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Dear Matlab community,
I am running an ANCOVA model in matlab. I have a Y variable, and an X variable, a Group variable (3 groups), and 2 covariates I would like to account for.
My ultimate goal would be to 1. see if there is a general relationship between Y and X and 2. if the slopes between Y and X differ between the 3 groups, while controlling for the 2 covariates.
I thus ended up using: mymodel = fitlm(mytable, 'Y~CV1 + CV2 + X*G').
I end up with a significant model based on the F and p value, and when running anova(mymodel), the X*G term has a significant p-value, which from my understanding of the AOCTOOL tutorial, means that the slopes are different between the three 3 groups.
However, since AOCTOOL only allows for one covariate, I ended up using the fitlm function, which doesn't return a stats object which I can use multcompare with, to answer the question as to how the slope of groups differ (e.g. which one is statistically bigger compared to the other etc.).
Can anyone provide information as to how I can find out how the slopes differ in the context of my model?
Thank you,
Paul
0 Kommentare
Antworten (0)
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!