質問

Is than an equivalent property to XTick for a 3D plot? Also, is there a way to determine the number output format for the axis tick marks?

役に立ちましたか?

解決

XTick is a property of axes, not plot. Whenever you use plot3, you draw on axes. Thus, it is relevant.

Instead of using XTick, you can use XTickLabel. It is a cell array of strings, so you can format them beforehand, by using sprintf.

x = 1:0.1:10;
y = x.^2;
z = sin(x);
figure;plot3(x,y,z);
set(gca,'XTickLabel',{'1' sprintf('%2.2f',pi) '3','4','5','John Doe'});
ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top