How to prevent axis off from removing the subtitle?

4 visualizaciones (últimos 30 días)
hmhuang
hmhuang el 27 de Oct. de 2021
Comentada: Chris el 27 de Oct. de 2021
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...)

Respuestas (1)

Chris
Chris el 27 de Oct. de 2021
Editada: Chris el 27 de Oct. de 2021
img = imread('cameraman.tif');
figure;
tiledlayout(1,1)
imagesc(img);
title('A');
subtitle('B');
axis off
tiledlayout requires R2019b or newer.
  1 comentario
Chris
Chris el 27 de Oct. de 2021
For older versions of Matlab:
img = imread('cameraman.tif');
figure;
subplot(1,1,1)
imagesc(img);
title('A');
subtitle('B');
axis off

Iniciar sesión para comentar.

Categorías

Más información sobre Graphics Object Programming en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by