How to remove axis from a sparsity plot with spy function?

3 次查看(过去 30 天)
Hello,
I plot the sparsity of a matrix with spy, like this:
a = rand(5, 2);
spy(a)
So it comes with x and y axis, and
nz = 10
on the bottom, which is completely normal. Does anyone know how to remove these axis and 'nz = 10'?
Thanks!

采纳的回答

KSSV
KSSV 2017-10-12
axis off
  3 个评论
KSSV
KSSV 2017-10-12
a = rand(5, 2);
spy(a)
set(gca,'xticklabel',{[]})
set(gca,'yticklabel',{[]})
delete(findall(findall(gcf,'Type','axe'),'Type','text'))

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Discrete Data Plots 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by