4.0

4.0 | 2 ratings Rate this file 220 downloads (last 30 days) File Size: 3.94 KB File ID: #6400

SHADOWPLOT

by Scott Hirsch

 

27 Nov 2004 (Updated 12 Sep 2007)

Code covered by BSD License  

Add a shadow to an existing surface plot.

Editor's Notes:

This file was a File Exchange Pick of the Week

Download Now | Watch this File

File Information
Description

SHADOWPLOT Add a shadow to an existing surface plot
 
For some surface plots, it can be helpful to visualize the shadow (2D projection) of the surface. This can give a quick perspective on the data's variance.
 
SHADOWPLOT PLANE Adds a shadow plot on the PLANE boundary

PLANE can be:
x, y, or z: Plots on back/top wall of x, y or z
1 .. 6 : Plots on Nth wall, numbered as in AXIS:
[xmin xmax ymin ymax zmin zmax]
 
SHADOWPLOT(HAX,PLANE) Adds a shadow plot on the Nth wall on axes HAX
HS = SHADOWPLOT(...) Returns a handle to the shadow (a patch)
 
Examples:
     figure
     surf(peaks)
     shading interp
     shadowplot x % Back X Wall
     shadowplot y % Back Y Wall

MATLAB release MATLAB 7.0.1 (R14SP1)
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (2)
16 Jan 2006 John D'Errico

I liked the idea until I tried it out. Shadowplot is of limited use in its current form. It works very nicely on the output of peaks, so then I tried it on one of my own 3d plots. It fails on more general patch objects, able to work on only objects of type 'surface'.

30 Jan 2006 John D'Errico

Its former self is only a "shadow" of what it is now. Sorry. I had to say it. 8-)

Please login to add a comment or rating.
Updates
26 Jan 2006

Including nice enhancements from John D'Errico to include patches, too (it used to support just surfaces).

12 Sep 2007

Now includes limited support for data inside of HGTRANSFORMS. Thanks to Patrick Barney for this enhancement.

Tag Activity for this File
Tag Applied By Date/Time
specialized Scott Hirsch 22 Oct 2008 07:36:35
plotting Scott Hirsch 22 Oct 2008 07:36:35
surface Scott Hirsch 22 Oct 2008 07:36:35
shadow Scott Hirsch 22 Oct 2008 07:36:35
3d Scott Hirsch 22 Oct 2008 07:36:35
3d Jeff grimes 15 Apr 2009 17:49:12
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com