matlab中title引入变量 [转载]

来源:互联网 发布:淘宝党卫军军服购买 编辑:程序博客网 时间:2024/05/16 08:09
原来的网址:http://imvlzn.blog.163.com/blog/static/17467327201519104927742/


1. 三行标题
a= 1; b= 2; c = 3; d= 4;
title( { 'Plot', ['a = ', num2str(a), 'b = ',num2str(b)], ['c = ', num2str(c),',d = ',...
num2str(d) ] } )
Notice:有两点,一是title中引入中括号[ ],每对中括号表示一行;二是多行[ ]用{ }括起来
2.两行标题
a = 1; b = 2; c = 3; d =4;
title( { 'Plot', ['a = ', num2str(a), ',b = ',num2str(b), ...
          ',c = ', num2str(c),', d= ',num2str(d) ] } )
**********************************************************
xlabel,ylabel,text,legend等中此用法类似
**********************************************************
#end
0 0
原创粉丝点击