samexaxis (nice subplots with same x axis)
ライセンスがありません
Features:
* Automatically sets xlim to the same for all subplots Removes xticklabels where it is not needed.
* Can join a subplots (if it is made with subplot instead of subaxis)
* Can set the ylabel position to the same for all subplots
* Can almost allways avoid that the yticklabels are written on top of each other
* Can automatically add a),b),c) to each subplot
----------
% helper function to clean up subplots that have common x axises
USAGE: samexaxis([optionalarguments])
Optional arguments:
* YAxisLocation (default='left') : choose left,right, alternate or alternate2
* XAxisLocation (default='bottom') : choose bottom,top or both
* YLabelDistance (default=1.4)
* Box (default='on')
* XTick
* XTickLabel
* XMinorTick
* ABC : add a),b),c), ... to each sub plot
* Join: joins the subplots vertically
* YTickAntiClash: try to aviod yticklabel clashes (default=false)
Example:
subplot(3,1,1);
plot(randn(100,1),randn(100,1),'x');
ylabel('QF')
subplot(3,1,2);
plot(randn(100,1),randn(100,1)*10,'x');
ylabel('HT');
subplot(3,1,3);
plot(randn(100,1),randn(100,1)*33,'x');
ylabel('DV');
samexaxis('abc','xmt','on','ytac','join','yld',1)
引用
Aslak Grinsted (2024). samexaxis (nice subplots with same x axis) (https://www.mathworks.com/matlabcentral/fileexchange/7169-samexaxis-nice-subplots-with-same-x-axis), MATLAB Central File Exchange. に取得済み.
MATLAB リリースの互換性
プラットフォームの互換性
Windows macOS Linuxカテゴリ
タグ
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!バージョン | 公開済み | リリース ノート | |
---|---|---|---|
1.0.0.0 | Made more clever ytickanticlash. Should no longer hide lines exactly at the ylimits. And it will not change ylimits of axes that doesn't have ylim set to auto. |