MATLAB绘图
2011-06-02 09:29
190 查看
以前用MATLAB绘图,都很简单,没想到居然还可以这么丰富~~
绘制一幅正弦曲线:
绘制坐标轴紧邻的子图:
绘制一幅正弦曲线:
%adjust default figure properties to improve quality figure; set(gcf,... 'DefaultLineLineWidth',1,'DefaultAxesLineWidth',.5,... 'DefaultAxesFontName','Helvetica',... 'DefaultAxesFontSize',20,... 'DefaultAxesTickLength',[0.02,0.02],... 'DefaultAxesXMinorTick','on','DefaultAxesYMinorTick','on'); set(gcf,'DefaultLineMarkerSize',8); % plot your data here x=0:0.3:2*pi; y=sin(x); plot(x,y,'o-','displayname','$y=/sin (x)</p>); xlabel('$x</p>,'interpreter','latex'); ylabel('$y</p>,'interpreter','latex'); h=legend('show'); set(h,'interpreter','latex'); title('http://asc.2dark.org'); %save your figure and export to eps format hgsave('example.fig'); print('-depsc','example.eps');
绘制坐标轴紧邻的子图:
x=0:0.3:2*pi; figure; h1=subplot(1,3,1); plot(x,sin(x)); h2=subplot(1,3,2); plot(x,cos(x)); h3=subplot(1,3,3); plot(x,sin(x-1)); set(h1,'position',[0.1,0.1,0.26,0.8]); set(h2,'position',[0.36,0.1,0.26,0.8],'yticklabel',''); set(h3,'position',[0.62,0.1,0.26,0.8],'yaxislocation','right');
相关文章推荐
- MATLAB GUI设计之读取串口数据并计算绘图
- MATLAB学习笔记(五)——MATLAB绘图
- Matlab绘图系列之高级绘图
- 关于matlab绘图中字体及图片大小等的设置
- MATLAB绘图与图形处理(1)
- Matlab绘图
- Matlab绘图
- Matlab二维曲线绘图
- matlab之串口数据采集绘图
- matlab 绘图字体大小控制
- Matlab数据可视化(4):一维数据绘图 II
- Matlab绘图方法汇总
- 六、Matlab 之 绘图操作(下)
- MATLAB plot 绘图的一些经验,记下来,facilitate future work
- MATLAB中示波器数据的绘图与保存
- Ardunio mpu6050 dmp 数据通过串口实现与matlab(mac)实时绘图 学习过程 【2014-9-8】
- MATLAB 句柄绘图
- Matlab绘图高级部分
- Matlab绘图-很详细,很全面
- Matlab中的高级绘图