matlab绘图学习基础.ppt

* * * * * * * * * * * * * * * * * * * * scatter3(X,Y,Z,S,C):绘制三维散点图. [x,y,z]=sphere(16); X=[x(:)*.5 x(:)*.75 x(:)]; Y=[y(:)*.5 y(:)*.75 y(:)]; Z=[z(:)*.5 z(:)*.75 z(:)]; S=repmat([1 .75 .5]*10,prod(size(x)),1); C=repmat([1 2 3],prod(size(x)),1); scatter3(X(:),Y(:),Z(:),S(:),C(:),filled),view(-60,60) x=1:10; y=rand(size(x)); bar(x,y); x = linspace(0,2*pi,30); y = sin(x); e = std(y)*ones(size(x)); errorbar(x,y,e); title(误差棒形图) theta=linspace(0, 2*pi); r=cos(4*theta); polar(theta, r); title(极坐标图) x=0:pi/10:2*pi; y=2*sin(x); subplot(2,2,1);bar(x,y,g); title(bar(x,y,g));axis([0,7,-2,2]);

文档评论(0)

1亿VIP精品文档

相关文档