How to plot the on-off status matrix with elements displayed

조회 수: 3 (최근 30일)
Rongxing Hu
Rongxing Hu 2022년 5월 11일
댓글: Rongxing Hu 2022년 5월 16일
I want to plot a figure like this with matlab. The elements are presented and marked with differetn colors.

답변 (1개)

Walter Roberson
Walter Roberson 2022년 5월 11일
image() with a colormap with two entries. If you need the labels then text() them into place. You can use find() to get row and column numbers. Remember that row numbers are y coordinates and column numbers are x coordinates.
  댓글 수: 1
Rongxing Hu
Rongxing Hu 2022년 5월 16일
How can I draw the edges for each small colored squares and scale the colorbar(0 the min -color and 1 the max-color).

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Color and Styling에 대해 자세히 알아보기

제품


릴리스

R2019b

Community Treasure Hunt

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

Start Hunting!

Translated by