Is there a way to plot multiple boxplots in a subplot?
Mostra commenti meno recenti
F(sub,day).Cond(Cond).Targ(TarInd_y,TarInd_x).RT(trcnt(Cond,TarInd_y,TarInd_x))=RT;
figure;
for day=1:1
for Cond=1:3
for sub=1:1
for r=1:rows
for c=1:columns
subplot(rows,columns,(r-1)*columns+c), hold on;
boxplot(F(sub,day).Cond(Cond).Targ(r,c).RT)
xticklabels({'Cond One', 'Cond Two', 'Cond Three'});
end
end
end
end
end
%F(1, 1).Cond(1).Targ(1, 1).RT this would be==>%Subject 1 Day one conditions 1:3,Target row 1 column 1(aka top
%left).Reaction time values
So I have some data from an experiment where I had subjects come in on 3 different days for a hand reaching task. In this experiment we had right, left and choice (subject chooses between r and l hand to reach to a target) trials.
I am trying to plot the reaction time values (a vector of 10 values for cond=1 or 2, 20 for cond=3) for all 33 targets (3 rows of 11 columns) for one subject for each different condition (3) as it's own boxplot in a subplot. The code above plots the boxplots on top of one another.
The question is very simple: is there a way to plot cond=1 trials/RT values as the first x-axis tick boxplot and cond2 and cond 3 as second and third tick on the x-axis.
Thanks!
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Axis Labels in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

