随笔分类 - MATLAB
摘要:pos1 = [0.05 0.4 0.3 0.3];subplot('Position',pos1)y = magic(4);plot(y)title('First Subplot') pos2 = [0.5 0.15 0.4 0.7];subplot('Position',pos2)bar(y)t
阅读全文
摘要:x=[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]y=[1.2, 3, 4, 4, 5, 4.7, 5, 5.2, 6, 7.2]p2=polyfit(x,y,2)p3=polyfit(x,y,3)y2=polyval(p2,x)y3=polyval(p3,x)hold onplot
阅读全文