How can I make a bar graph using only max/min values with std dev line on both ends?
8 次查看(过去 30 天)
显示 更早的评论
It would be similar to this picture, except without the red line through each bar. I just have the max value and min value of each bar. I also have the upper and lower standard deviation.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/886220/image.png)
0 个评论
回答(1 个)
Turlough Hughes
2022-2-6
编辑:Turlough Hughes
2022-2-6
x = rand(10,3);
boxplot(x);
Normally (at least for most other plot functions) you could do this sort of thing with a name-value pair argument or by getting the handle for example with h = boxplot(x) and then modifying the properties there. However, I didn't see any options to remove or hide the red line with those approaches. So I suggest using findobj as follows:
figure(), boxplot(x)
h = findobj(gca,'Tag','Median');
delete(h)
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Graphics Object Identification 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!