Search code examples
matlabsavematlab-figure

Saving 2D projections of 3D plots


I have made a 3D scatter plot with three sets of data. I would like to save 2D projections of this 3D plot using the saveas function to .jpg, .png, or other similar file format. By default, the saveas function, when passed the plot3 object, saves the 2D xy-plane projection, but I also want the yz and xz projections. How can I save those as well?


Solution

  • Use function to change view/camera angle for a 3D plot, e.g. view(-90, 90) then call saveas function again.