Controlling Y-Axis Label Properties on Multi-Axis Plots
1 回表示 (過去 30 日間)
古いコメントを表示
Hi all,
I'm using plotyy to make a graph of my data, but I cannot figure out how to programmatically edit the y-axis labels. Specifically, I would like to change the font size. Because I'm using plotyy, ylabel is off the table. Using set(ax,'FontSize',value) only affects the axis tick labels, x label, and legend.
Thanks,
Clay
0 件のコメント
回答 (1 件)
Luffy
2012 年 7 月 10 日
For example:
x = 0:0.01:20;
y1 = 200*exp(-0.05*x).*sin(x);
y2 = 0.8*exp(-0.5*x).*sin(10*x);
[AX,H1,H2] = plotyy(x,y1,x,y2,'plot');
set(get(AX(1),'Ylabel'),'String','Slow Decay') ;
set(get(AX(2),'Ylabel'),'String','Fast Decay');
set(get(AX(2),'Ylabel'),'FontSize',30); % You can replace 30 with size you want.
% Similarly for other axis.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Axis Labels についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!