I have two ranges of x = [0:0.01:1] and x = [2:0.01:3] and I want to plot x vs. Y in one plot for the two rages of x values without using hold on command. Is it possible in matlab?
Below I have used hold on command (which I don't want to use) to plot
x = [0:0.01:1] Y = x./5; plot(x, Y, 'Color',[0.85 0.16 0], 'linewidth', 2); hold on x = [2:0.01:3] Y = x./5; plot(x, Y, 'Color',[0.85 0.16 0], 'linewidth', 2);
No products are associated with this question.
Something like this?
x = [0:0.01:1 nan 2:0.01:3] y = x./5 plot(x,y)