A function that outputs multiple plots?

4 个评论

There are already many Matlab functions that output plots.
alpedhuez for example the function "step" plots step response of a system. or the function "spectrogram" plots the fourier transform spectrum.

请先登录,再进行评论。

 采纳的回答

function plotoutput()
x = 1:10;
y = x.*x;
plot(x,y)
when you call the function, it shows a figure.

3 个评论

Multiple plots, not just one!
function plotoutput()
x = 1:10;
y1 = x.*x;
y2 = x + 1;
figure(1);plot(x,y1)
figure(2);plot(x,y2)

请先登录,再进行评论。

更多回答(0 个)

类别

帮助中心File Exchange 中查找有关 Labels and Styling 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by