How to plot two equal parts of axis y with unequal distances?
조회 수: 1 (최근 30일)
이전 댓글 표시
hello.
I have this plot:

I want it to be like this:

thanks a lot
댓글 수: 0
답변 (1개)
Star Strider
2021년 9월 17일
Set the tick locations (and displayed values if different) to specific values, and specify the tick format —
x = zeros(1,5);
y = 1:6:30;
figure
scatter(x, y, 35, y, 's', 'filled')
yticks([0 4 15 30]) % Set 'Y-Tick' Values (R2016b+)
ytickformat = '\bf %d'; % Set Bold Font Weight & Integers (R2016b+)
xlim([0 0.1])
.
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!