How to show multiple colors in the same slots? (imagesc)
조회 수: 1(최근 30일)
표시 이전 댓글
Hi all,
我有一个显示亮度图像(x, y),其中一个是index of the best strategy to achieve something, let's say between 1 and 10, as a function of two parameters: x, and y.
I created a colormap to associate to each
a color, and in case there are at least two strategies that perform the same an 11th color. to reppresent "Tie", when two strategies have the same score.
Is there a way to show in a single slot multiple colors? (l2 colors would be enough) I was thinking of two triangles colored with the colors of that strategy.
Thank you!
댓글 수: 0
채택된 답변
DGM
2022년 4월 8일
편집:DGM
2022년 4월 8일
If each element of A represents a single "slot", then no. A pixel can be represented by only one color tuple.
If you create a larger image, such that the elements of A are represented as (e.g.) 5x5 superpixels, then you could do something to conditionally subdivide the superpixel into two regions with different colors. You would likely need to also do something to manage the change in axis range so that your labels remain useful.
댓글 수: 2
Image Analyst
2022년 4월 8일
I'm waiting to see a mockup of what you have, and what you'd like to have instead.
추가 답변(0개)
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!