How to prevent axis off from removing the subtitle?
2 次查看(过去 30 天)
显示 更早的评论
How to prevent axis off from removing the subtitle? Nemely, I just want to remove the x, y axes but not the subtitle itself.
img = imread('cameraman.tif');
figure;
imagesc(img);
title('A');
subtitle('B');
If I add axis off at the end it gives me: (The subtitle B is gone...)
0 个评论
回答(1 个)
Chris
2021-10-27
编辑:Chris
2021-10-27
img = imread('cameraman.tif');
figure;
tiledlayout(1,1)
imagesc(img);
title('A');
subtitle('B');
axis off
tiledlayout requires R2019b or newer.
1 个评论
Chris
2021-10-27
For older versions of Matlab:
img = imread('cameraman.tif');
figure;
subplot(1,1,1)
imagesc(img);
title('A');
subtitle('B');
axis off
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Line Plots 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!