markersize, 调整标记大小
linewidth, 调整线宽
标记格式
标记
'marker','o'
'o' 圆圈
'+' 加号
'*' 星号
'.' 点
'x' 叉号
'square' 或 's' 方形
'diamond' 或 'd' 菱形
'^' 上三角
'v' 下三角
'>' 右三角
'<' 左三角
'pentagram' 或 'p' 五角星(五角形)
'hexagram' 或 'h' 六角星(六角形)
'none' 无标记
线形
'linestyle','-'
, 可以省略'linestyle'
'-' 实线
'--' 虚线
':' 点线
'-.' 点划线
'none' 无线条
颜色
标记的颜色: markeredgecolor
, markerfacecolor
; 线的颜色直接在线形里指定'linestyle', '-or'
.
[r g b] (需要除255归一化)
'red' 或 'r' 红色 [1 0 0]
'green' 或 'g' 绿色 [0 1 0]
'blue' 或 'b' 蓝色 [0 0 1]
'yellow' 或 'y' 黄色 [1 1 0]
'magenta' 或 'm' 品红色 [1 0 1]
'cyan' 或 'c' 青蓝色 [0 1 1]
'white' 或 'w' 白色 [1 1 1]
'black' 或 'k' 黑色 [0 0 0]
'none' 无颜色 不适用
set(gcf,'position',[10,10,2000,2000]) % 从屏幕的坐标(10,10)跨到(2000,2000)
subplot(2,3,4) % 2行3列, 第四个图
axis equal % 坐标轴等比例
axis([-2,3,-1.5,inf]) % x从-2到3, y下限是-1.5, 上限自动(设为inf)
xlabel('$P_{phi}/psi_{w}$','FontSize',16,'interpreter','latex')
interpreter可以选择latex
, tex
, none
legend('legend1','legend2',...)
图例和plot的顺序一一对应.
如果不想显示某个plot的图例, 给这个plot一个句柄, 然后关闭这个句柄的图例
a = plot(x3,y3,'k-',x3,z3,'k-',u3,s3,'k-',v3,r3,'k-',t3,w3,'k-','LineWidth',1);
set(a,'handlevisibility','off');
text(x,y,'comment')
title('your title', 'interpreter', 'none')
saveas(gcf, 'path')
可以保存为png或fig文件
原文:https://www.cnblogs.com/lijianming180/p/12402209.html