boxplot at uneven spacing
5 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Pankaj
am 9 Nov. 2019
Beantwortet: Akshay K A
am 12 Nov. 2019
rng('default') % For reproducibility
x1 = rand(5,1);
x2 = rand(10,1);
x3 = rand(15,1);
x = [x1; x2; x3];
g1 = repmat({'First'},5,1);
g2 = repmat({'Second'},10,1);
g3 = repmat({'Third'},15,1);
g = [g1; g2; g3];
% Create the box plots.
boxplot(x,g)
The above will boxplot at equal intervals, for which I can chang the xticks. What I want is to boxplot at uneven abscissa values, lets say at abscissa = [1.1, 2.5, 4.6]
Thanks
0 Kommentare
Akzeptierte Antwort
Akshay K A
am 12 Nov. 2019
Hi Pankaj,
Refer to Plot Appearance section in the Box Plot documentation link below:
'Positions' Name-Value Pair can be used to specify the abscissa vector.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!