Set y axis limits matlab plot
问题 I have the following normal distribution and i need to set the graph plot to 1.5 on y axis. x = -.5:0.0001:3.5; m1 = 1; s1 = 0.5; pdfNormal_1 = normpdf(x, m1, s1); ylim([0 1.5]) set(gcf,'color','w'); plot(x, pdfNormal_1)%, x, pdfNormal_2); Could someone tell me how to? Regards 回答1: The axis function is the one you need. you can set the axis to the values you want using axis([xmin xmax ymin ymax]) or you can play with it doing things like: axis equal axis tight axis off etc Go to the