Plot two or more multcompare results vertically in one figure
2 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hello,
The multcompare test plots the lines horizontaly while the model names on verticle axis. How can I plot the lines vertically and model names on horizontal axis similar to the give figure. Morever, how can I show the results of two(or more) multicopmare tests in one figure (considerint the results as group data).
Any simple example could be used e.g.,
load carsmall % load data
[p,t,stats1] = anova1(MPG,Origin,'off'); %test 1 for group 1
[c,m,h,nms] = multcompare(stats1); %multicompare 1 for group 1
[p,t,stats2] = anova1(MPG+4,Origin,'off'); %test 2 for group 2
[c,m,h,nms] = multcompare(stats2); %multicompare 2 for group 2
However, I need the output similar to the attached figure
0 commentaires
Réponses (1)
Aditya
le 27 Fév 2023
Hi,
I understand that you want to have the figure rotated.
load carsmall % load data
[p,t,stats1] = anova1(MPG,Origin,'off'); %test 1 for group 1
[c,m,h,nms] = multcompare(stats1); %multicompare 1 for group 1
[p,t,stats2] = anova1(MPG+4,Origin,'off'); %test 2 for group 2
[c,m,h,nms] = multcompare(stats2); %multicompare 2 for group 2
camroll(90)
You can use Rotate 3D Tool of figure for changing orientation in general
For plotting together, there are many strategies. You can try using subplot
load carsmall % load data
[p,t,stats1] = anova1(MPG,Origin,'off'); %test 1 for group 1
camroll(90)
subplot(1,2,1)
[c,m,h,nms] = multcompare(stats1); %multicompare 1 for group 1
[p,t,stats2] = anova1(MPG+4,Origin,'off'); %test 2 for group 2
subplot(1,2,2)
[c,m,h,nms] = multcompare(stats2); %multicompare 2 for group 2
1 commentaire
Voir également
Catégories
En savoir plus sur Spectral Estimation dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!