Matlab 图片绘制相关
2016-06-08 11:25
701 查看
MatLab图片绘制相关:
1. 图中绘制直线:
3. 设定图中文字大小:
绘制双Legend:
1. 图中绘制直线:
line([0.7,0.7],[100,400],'color','c','linestyle','--','linewidth',2);2.LaTex格式标题:
z = xlabel('$$ $$ '); set(z,'Interpreter','latex','FontSize',17,'FontWeight','bold');
3. 设定图中文字大小:
set(get(gca,'XLabel'),'FontSize',17); set(get(gca,'YLabel'),'FontSize',15); set(gca,'FontSize',13);4. 旋转Y轴label:
ylabel('PSNR','FontName','Times New Roman','FontSize',14,'Rotation',0);5.绘制双Y坐标轴:
[AX,H1,H2] = plotyy([1:N],Efficient,[1:N],Result(:,1),'plot'); set(AX(1),'XColor','k','YColor','b'); set(AX(2),'XColor','k','YColor','r'); HH1=get(AX(1),'Ylabel'); set(HH1,'String','something'); set(HH1,'color','b'); HH2=get(AX(2),'Ylabel'); set(HH2,'String','something'); set(HH2,'color','r'); set(H1,'LineStyle','-'); set(H1,'color','b'); set(H1,'LineWidth',2); set(H2,'LineStyle','--'); set(H2,'color','r'); set(H2,'LineWidth',2); legend([H1,H2],{'';''});
z = xlabel('i$$ $$ Synapse'); set(z,'Interpreter','latex','FontSize',15,'FontWeight','bold'); title('Bidirectional Loop'); line([0 10],[181 181],'linestyle','--','color','r','Linewidth',2,'parent',AX(2)); set(AX,'FontSize',13); set(gca,'xtick',[1:N]); set(get(AX(2),'Ylabel'),'FontSize',12); set(get(AX(1),'Ylabel'),'FontSize',12); set(get(AX(1),'Xlabel'),'FontSize',15); set(get(AX(1),'title'),'FontSize',13);6.
绘制双Legend:
h1 = plot(index,Contribution(2,:),'k*-','LineWidth',2); hold on; h2 = plot(index,Contribution(4,:),'cx:','LineWidth',2); hold on; h3 = plot(index,Contribution(1,:),'go-','LineWidth',2); hold on; h4 = plot(index,Contribution(5,:),'bx--','LineWidth',2); hold on; h5 = plot(index,Contribution(7,:),'r*-','LineWidth',2); l1 = legend([h1,h2],'2th Synapse','4th Synapse'); copyobj(l1,gcf); l2 = legend([h3,h4,h5],'1th Synapse','5th Synapse','7th Synapse'); xlabel('n'); ylabel('Contribution'); set(get(gca,'title'),'FontSize',15); set(get(gca,'YLabel'),'FontSize',15); set(get(gca,'XLabel'),'FontSize',15); set(gca,'FontSize',13);7. 设定横坐标标度内容:
xlabel('JPEG','FontName','Times New Roman','FontSize',14); ylabel('EBR','FontName','Times New Roman','FontSize',14,'Rotation',0); set(gca,'FontName','Times New Roman','FontSize',14); set(gca, 'XTick', [1 2 3 4]); set(gca,'XTickLabel',{'30','50','70','90'});8. 绘制散点图:
for i=1:PreStepMat_y ArrayTmp = PreStepMat(:,i); scatter(Sparse,ArrayTmp,'b*'); hold on; end
相关文章推荐
- 解析在main函数之前调用函数以及对设计的作用详解
- 详解Matlab中 sort 函数用法
- java和matlab画多边形闭合折线图示例讲解
- C#调用Matlab生成的dll方法的详细说明
- 简述Matlab中size()函数的用法
- 从java中调用matlab详细介绍
- 稀疏自动编码器 (Sparse Autoencoder)
- 详解Matlab中 sort 函数用法
- 简述Matlab中size()函数的用法
- VC++与Matlab混合编程的快速实现
- Matlab 矩阵运算
- matlab与opencv部分函数的对照
- matlab神经网络工具箱创建神经网络
- Matlab
- MATLAB 入门教程
- matlab函数_连通区域
- MATLAB中函数模式和命令模式的区别
- MATLAB 添加自定义的模块到simulink库浏览器
- Export Figures for LaTeX Writing