필터 지우기
필터 지우기

Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

is there a way to fix the color axis so that similar data values take up similar color values even if the data range has changed ?

조회 수: 1 (최근 30일)
Hi, I have a query regarding subplots and mapping values onto colormap (gray). I have a set of 2D matrices with different minimum and maximum values for each. I would like to subplot these different matrices using imagesc but scale them all with respect to a global maximum and minimum. So if a subplot is noisy it would have colors close to black i.e. 0. This way I can differentiate good data from noisy ones straight away. I have tried using caxis with fixed values corresponding to global max and min but it doesn't seem to do the job. I am wondering if there is a way to fix a color to a particular data value irrespective of the data range. Thanks in advance, Stanley

답변 (2개)

Walter Roberson
Walter Roberson 2011년 9월 28일

Image Analyst
Image Analyst 2011년 9월 28일
You can use imshow() instead of imagesc and if you do that you can set the scaling upper and lower limits yourself. imagesc determines them from your data so it will be different for all of them. You can use whatever colormap you want - all of them will use that colormap and each color will correspond to a certain value no matter what axes it's in or what the range of data in that axes is.

이 질문은 마감되었습니다.

Community Treasure Hunt

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

Start Hunting!

Translated by