How to make output X Y graph like the picture?

조회 수: 2 (최근 30일)
Zaky Ghalib
Zaky Ghalib 2023년 5월 17일
댓글: Mathieu NOE 2023년 5월 22일
can you help me, How to make output X Y graph like the picture?

답변 (1개)

Mathieu NOE
Mathieu NOE 2023년 5월 17일
hello
you simply have to remember that vertical lines need you to duplicate the x value (with different y values of course)
like in this example x = 2 for both y = 1 and 2
x = [1 2 2 3];
y = [1 1 2 2];
plot(x,y,'linewidth',5);
xlim([0 4]);
ylim([0 3]);

카테고리

Help CenterFile Exchange에서 Mathematics에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by