New Reply

Truncating a surface plot in Matlab

 
Share Thread Thread Tools
Sep29-11, 08:11 PM   #1
 

Truncating a surface plot in Matlab


Hi,
My thesis involves several surface plots. Most of the interesting features of these plots (and also the region I am interested in) are between z=0 and z=0.2, but there are a few points that have values as high as z=4. I want to view only the region of interest, so I use

Code:
zlim([0 0.2])
This works fine in the sense that it zooms in on the region of interest, but it does not truncate parts of the plot above z=0.2. This means that the surface extends above the axes, all the way up to the top of the figure when viewed from an oblique angle. Cosmetically, I feel this is unacceptable for a thesis, and I would like the plot to be truncated at the axis limits without affecting the location of the points.

I am okay with it either 'cutting' the top off, or flattening it at the top, but would probably prefer the former. Unfortunately, changing the actual values in this region (by setting any point with a value greater that z=0.2 to 0.2) changes the actual shape of the surface between these points and the neighbouring points.

There must be simple solution for this, but I can't find one. Hopefully someone has some ideas. Thanks in advance.
PhysOrg.com
PhysOrg
science news on PhysOrg.com

>> King Richard III found in 'untidy lozenge-shaped grave'
>> Google Drive sports new view and scan enhancements
>> Researcher admits mistakes in stem cell study
New Reply
Thread Tools


Similar Threads for: Truncating a surface plot in Matlab
Thread Forum Replies
Matlab 3D plot General Engineering 2
3D Matlab plot Math & Science Software 4
truncating a vector from an addressed element in MatLab Math & Science Software 1
MATLAB: 3D plots- How to plot 3D lines rather than surface? Math & Science Software 2
Surface Plot in Matlab (Cylindrical Coordinates) Math & Science Software 1