Axis 'boxstyle' 'full' only works if 'xaxislocation' is 'origin'!!
5 ビュー (過去 30 日間)
古いコメントを表示
Another one ...
Try this:
figure;surf(peaks);view(2);axis tight;shading interp;box on
set(gca,'BoxStyle','full','XAxisLocation','bottom')
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/169399/image.png)
Now try:
set(gca,'XAxisLocation','origin')
And that's ok!
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/169401/image.png)
I'm on Matlab R2017b under Windows 10 64 bits
0 件のコメント
回答 (1 件)
Jordy Jose
2018 年 1 月 31 日
Hi Luc,
The box is actually there but the surface is being rendered on top of it (because the axis is tight). You can render the rulers on top of the surface by setting the layer to 'top' on the axes.
a = gca; a.Layer = 'top'
Another workaround is to keep the rulers on layer 'bottom,' but increase the LineWidth of the axes. A value of 1.5 or greater should work.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Title についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!