Having trouble getting 3D plots into the kind of orintation where the x-axis is horizontal, z-axis is vertical and y is angled into the page, shown in the following diagram. The i have tried the view function and messed with camera angles somewhat, any suggestions is welcomed thanks
Screen Shot 2019-04-15 at 2.23.07 AM.png

3 件のコメント

madhan ravi
madhan ravi 2019 年 4 月 14 日
編集済み: madhan ravi 2019 年 4 月 14 日
view(2) %?
view([0,45])
John Xing
John Xing 2019 年 4 月 14 日
That doesn't keep the x-axis hoizontal.
Xiao Yang
Xiao Yang 2019 年 12 月 28 日
Hi John,
I am having the same problem as you. Have you figured out a way to achieve this?
Thank you!

サインインしてコメントする。

回答 (1 件)

Walter Roberson
Walter Roberson 2019 年 4 月 14 日

0 投票

You will not be able to achieve that using view() alone. In order to keep the X axis horizontal while having the Y axis angled, you need a sheer transform, which view() does not provide (view provides rotations.)
You might be able to achieve it by manipulating the low-level camera properties https://www.mathworks.com/help/matlab/creating_plots/low-level-camera-properties.html such as CameraPosition and CameraTarget .
Otherwise, you might have to proceed by parenting the surface to a hgtransform group and setting the transform matrix to appropriate angle and sheer. makehgtform() can help in setting up the right transform matrix. However, I am presently not confident that you can get the axes box at the desired angle unless you draw it yourself.

質問済み:

2019 年 4 月 14 日

コメント済み:

2019 年 12 月 28 日

Community Treasure Hunt

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

Start Hunting!

Translated by