Changing clim on previous imagesc in a subplot

1 回表示 (過去 30 日間)
Mason
Mason 2013 年 2 月 8 日
Hello,
I am making imagesc subplots and at the end i am finding max values within a loop.
I tried using h = imagesc() then "set(h, 'CLim', [somevalue, somevalue])" but then found out you cant use handles in this way with imagesc.
How can i change the clim values on those plots?
Thanks!

採用された回答

Walter Roberson
Walter Roberson 2013 年 2 月 8 日
imagesc() does not itself create subplots. subplot() creates subplots. You need to record the output from the subplot() call and use it as the handle for the set()
thisax = subplot(2,3,5); %for example
imagesc()
set(thisax, 'CLim', [somevalue, somevalue]);

その他の回答 (1 件)

Mason
Mason 2013 年 2 月 8 日
ah ha! awesome, thanks! Makes total sense.

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by