24小时热门版块排行榜    

查看: 5868  |  回复: 5

黑曼巴1991

铁杆木虫 (正式写手)

[求助] Matlab中set(gca,'XTickLabel',({'width height'})); 怎么把width height换成两行 已有1人参与

Matlab中set(gca,'XTickLabel',({'width height'}));  怎么把width height换成两行,即:
width
height
回复此楼

» 猜你喜欢

» 本主题相关价值贴推荐,对您同样有帮助:

已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

dbb627

荣誉版主 (著名写手)

【答案】应助回帖

感谢参与,应助指数 +1
set(gca,'XTickLabel',({'width';
    'height'}));
The more you learn, the more you know, the more you know, and the more you forget. The more you forget, the less you know. So why bother to learn.
2楼2015-07-16 15:11:25
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

黑曼巴1991

铁杆木虫 (正式写手)

引用回帖:
2楼: Originally posted by dbb627 at 2015-07-16 15:11:25
set(gca,'XTickLabel',({'width';
    'height'}));

不对啊 这样只有width了
Matlab中set(gca,'XTickLabel',({'width height'})); 怎么把width height换成两行
1.jpg

3楼2015-07-16 15:30:15
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

dbb627

荣誉版主 (著名写手)

【答案】应助回帖

★ ★ ★ ★ ★
黑曼巴1991: 金币+5, ★★★★★最佳答案, 好的 谢谢了 我用其他方法间接处理了 2015-07-16 16:12:05
不明白你要整成啥样
x=1:0.5:10
y=x.^2+0.3*x+5;
plot(x,y)
set(gca,'XTickLabel',({'width';
'height'}));
Matlab中set(gca,'XTickLabel',({'width height'})); 怎么把width height换成两行-1
untitled.jpg

The more you learn, the more you know, the more you know, and the more you forget. The more you forget, the less you know. So why bother to learn.
4楼2015-07-16 15:42:57
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

adcpk

金虫 (初入文坛)

你干嘛要弄成两行,为了好改吗?这样行吗

xl='width';
yl='height';
set(gca,'XTickLabel',({[xl,' ',yl]}));

[ 发自小木虫客户端 ]
5楼2015-07-16 23:26:27
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖

farina27

新虫 (初入文坛)

您好,请问您解决这个问题了吗?请问怎样可以实现换行呢
6楼2018-09-16 18:03:51
已阅   回复此楼   关注TA 给TA发消息 送TA红花 TA的回帖
相关版块跳转 我要订阅楼主 黑曼巴1991 的主题更新
信息提示
请填处理意见