The code doesn't generate a graph. Please tell where I am doing wrong.
조회 수: 3 (최근 30일)
이전 댓글 표시
clc, clear, close all
x = 1;
for n = 1:30
y = (7259/14520)*x + 167/2420
plot(n,y,'color','m')
hold on
x = y;
end
댓글 수: 0
답변 (1개)
KSSV
2022년 4월 4일
You have to use a marker, as you are plotting point by point.
x = 1;
for n = 1:30
y = (7259/14520)*x + 167/2420
plot(n,y,'.','color','m')
hold on
x = y;
end
댓글 수: 3
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

