12.07.2015 Views

MATLAB Function Reference (Volume 2: Graphics)

MATLAB Function Reference (Volume 2: Graphics)

MATLAB Function Reference (Volume 2: Graphics)

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

coneplotIt is usually best to set the data aspect ratio of the axes before calling coneplot.You can set the ratio using the daspect command,daspect([1,1,1])ExamplesThis example plots the velocity vector cones for vector volume datarepresenting the motion of air through a rectangular region of space. The finalgraph employs a number of enhancements to visualize the data moreeffectively. These include:• Cone plots indicate the magnitude and direction of the wind velocity.• Slice planes placed at the limits of the data range provide a visual context forthe cone plots within the volume.• Directional lighting provides visual queues as to the orientation of the cones.• View adjustments compose the scene to best reveal the information contentof the data by selecting the view point, projection type, and magnification.Load and Inspect DataThe winds data set contains six 3-D arrays: u, v, and w specify the vectorcomponents at each of the coordinate specified in x, y, and z. The coordinatesdefine a lattice grid structure where the data is sampled within the volume.It is useful to establish the range of the data to place the slice planes and tospecify where you want the cone plots (min, max).load windxmin = min(x(:));xmax = max(x(:));ymin = min(y(:));ymax = max(y(:));zmin = min(z(:));Create the Cone Plot• Decide where in data space you want to plot cones. This example selects thefull range of x and y in eight steps and the range 3 to 15 in four steps in z(linspace, meshgrid).• Use daspect to set the data aspect ratio of the axes before calling coneplotso <strong>MATLAB</strong> can determine the proper size of the cones.2-96

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!