How to remove box in heatmap ?

조회 수: 19 (최근 30일)
도현 김
도현 김 2021년 3월 29일
편집: Walter Roberson 2021년 3월 29일
example )
plot(1:10)
set(gca,'box','off')
%%%%%%%%%%%
i want )
h = rand(10)
heatmap(h,'box','off') ...... but cannot use 'box' in heamap.
I want to remove the outline.
Could there be any way ?

채택된 답변

Walter Roberson
Walter Roberson 2021년 3월 29일
편집: Walter Roberson 2021년 3월 29일
Possibly, but it would not be easy. You would have to use struct() on the heatmap object in order to get at internal parts of it, and you would have to figure out exactly which internal part to change.
For example it turns out you can change some of the text by recording the heatmap handle (call it HH) and altering
HH.NodeChildren(1).NodeChildren(1).String
but
HS = struct(HH);
HS.Axes.Box = 'off'
has no effect.
and digging in to
HS = struct(HH);
Hg = struct(HS.Heatmap.Grid);
and trying to set the grid properties has no visible effect.
heatmap objects are unfortunately barely customizable through supported interfaces.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Data Distribution Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by