red-green colour blind

조회 수: 22 (최근 30일)
Megha
Megha 2019년 5월 7일
편집: Adam Danz 2019년 5월 7일
I am asked to replace red, green, blue curves in the plot to red-green colour blind.
Can someone please tell me how to get that code for color blind??
For example red is [1 0 0], green is [0 1 0], then color blind is [? ? ?]
  댓글 수: 3
Megha
Megha 2019년 5월 7일
Thank you KSSV, I can see entire colorbar for normal vision and color blind vision.
Can you please suggest what i should use in plot command i.e.
plot(x1,y1,'r'); hold on;
plot(x1,y2,'g'); hold on;
plot(x1,y3,'b'); hold on;
for my three different plots?
Adam Danz
Adam Danz 2019년 5월 7일
편집: Adam Danz 2019년 5월 7일
If you are avoiding colors that a red-green color deficient person has trouble seeing, use any of the colors in the "deuteranopia" column in the link shared by KSSV.
If you prefer to set the colors manually, go to this online color picker, choose a color, and copy the RGB values on the left. Divide those numbers by 255 to convert them to normalized values for matlab.
so rgb(255, 237, 40) becomes [255,237,40]./255 = [1, .929, .157]
You got this!

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

답변 (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