boxplot XTick label size

33 次查看(过去 30 天)
Carlos Minjarez
Carlos Minjarez 2011-3-3
Hi Matlab Users I have a problem with the boxplot function. I am doing the following:
axes('FontSize', 18,'FontName','arial');
boxplot(R,'labels',{'cocos','sandias','melones'})
la problem here is that XTickmark size does not chage to 18 points size while the YTickmark it does.
Do you have any idea of how I can fix this?
Thanks
carlos

回答(2 个)

Walter Roberson
Walter Roberson 2011-3-3
set(findobj(gca,'Type','text'),'FontSize',18)
boxplot() uses the default axes labeling for the Y axes, but for the X axes, it uses text() to put the labels in place and it does not grab the axes FontSize when it does so.
Note: it is likely that with an 18 point font that the labels will overlap the y=0 axes.
  5 个评论
Peng Zhong
Peng Zhong 2014-8-26
thank you,Nick. Very helpful.
desword jacky
desword jacky 2016-12-11
how to deal with the overlapping between the xticklabel and xlabel when the fontsize is 25?

请先登录,再进行评论。


Sav Deb
Sav Deb 2012-11-29
How to do the same but in Property Editor

类别

Help CenterFile Exchange 中查找有关 Axis Labels 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by