How can I move the axes rulers into the middle of axes within MATLAB 7.3 (R2006b)?

4 次查看(过去 30 天)
When I execute the following code:
x = 1:11;
t = 1:30;
for i=1:length(x)
xt(i,:) = t;
tz(i,:) = x(i)*ones(1,length(t));
z(i,:) = sin(2*pi*0.1*t);
end
h = plot3(xt',tz',z'); grid;
axis([min(min(xt)) max(max(xt)) min(min(tz)) max(max(tz)) min(min(z)) max(max(z))]);
view(-3,10);
I would like to set the x-axis and y-axis to the plane z=0 instead of z=-1 with a common origin 0.

采纳的回答

MathWorks Support Team
The ability to change the location of axes lines relative to the graphics objects is not available in MATLAB.
To work around this issue you can use a function submitted to MATLAB Central to draw the axes lines in the desired location. The following URL will lead you to the file:
<http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=3245>
Note that MathWorks does not guarantee or warrant the use or content of these submissions. Any questions, issues, or complaints should be directed to the contributing author.

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Grid Lines, Tick Values, and Labels 的更多信息

产品


版本

R2006b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by