%% Clear Current Axes
% Plot two sine waves. Then, clear the line plots from the axes.

% Copyright 2015 The MathWorks, Inc.


x = linspace(0,2*pi);
y1 = sin(x);
y2 = sin(2*x);

plot(x,y1)
hold on
plot(x,y2)

%%
cla
%%
% |cla| clears the line plots and resets the |ColorIndex| and
% |LineStyleIndex| properties of the axes to 1. Subsequent plots start
% from the beginning of the color order and line style order. For example,
% plot another sine wave.

y3 = sin(3*x);
plot(x,y3)
hold off