Hi all,
below scatter plot has two variables plotted against each other and a third variable provides the color. For the third variables most values lie between 1 and 10 and only one value is at 30 (hence the colorbar range from 0-30).
Is there a way that I can shift the color range so I get more variations in color between 0 and 10?
Thanks in advance!

댓글 수: 1

jonas
jonas 2018년 10월 8일
편집: jonas 2018년 10월 8일
Although possible, perhaps it would be more appropriate to use a logscale instead of an awkwardly scaled colorbar.

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

 채택된 답변

jonas
jonas 2018년 10월 8일
편집: jonas 2018년 10월 8일

0 개 추천

Here's a colorbar for you to give you an idea of how you can build your own. The colorscale is not very intuitive.
part1 = jet(200);
part2 = [linspace(part1(end,1),0,200)',zeros(200,2)];
cmap=[part1;part2];
colormap(cmap)
scatter(rand(1,100),rand(1,100),[],rand(1,100))
colorbar
EDIT: slight improvement

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Scatter Plots에 대해 자세히 알아보기

제품

질문:

2018년 10월 8일

댓글:

2018년 10월 9일

Community Treasure Hunt

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

Start Hunting!

Translated by