How to scale a plot to fit a plot window without white end

Whenever I plot data, there is some white space left on the right end. Is there a command to scale the plot all over the plot box ? In this case make the x-Axis show the data from 0-260
x = 0:260; % Create Data
y = rand(size(x)); % Create Data
figure(1)
plot(x, y)
I already tried axis([0 259 min(y) max(y)]); but this did not help

 채택된 답변

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

제품

릴리스

R2018b

질문:

2019년 1월 11일

댓글:

2019년 1월 11일

Community Treasure Hunt

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

Start Hunting!

Translated by