[no subject]

*To*: mathgroup at yoda.physics.unc.edu*From*: twj*Date*: Fri, 7 Aug 92 14:10:02 CDT

In reply to Simon Chandler <simonc at hpcpbla.bri.hp.com> >This does indeed plot a surface, however, there are two problems. >1. If the x and y values have different magnitudes the bounding box > for the surface is long and skinny. There does not seem to be any > automatic scaling of the axes or any options to control the axes. This is exactly what the option BoxRatios does. You are (probably) using the setting BoxRatios -> Automatic, use BoxRatios -> {1,1,1} for a cubical box. BoxRatios acts in an analogous fashion in three-dimensions to the way AspectRatio acts in two-dimensions. >2. The axes of the plot are not numbered so one cannot tell the > values of x and y from the plot. This rules out use of this function > to present experimental data where calibrated axes are essential. > Even ListPlot3D of data with reqularly spaced x and y values does > not allow one to calibrate the axes - the plot's axes are always > numbered with the array's row and column numbers. NO, if you use ListSurfacePlot3D you can set Axes and they will just work properly. Thus In[1]:= <<Graphics/Graphics3D.m In[2]:= apts = Table[ {Cos[t] Cos[ u], Sin[t] Cos[ u], Sin[u]}, {t,0,Pi, Pi/5}, {u,0,Pi/2, Pi/10}]; In[3]:= ListSurfacePlot3D[ apts] Out[3]= -Graphics3D- In[4]:= Show[ %, Axes -> True] Out[4]= -Graphics3D- You can't just do ListSurfacePlot3D[ apts, Axes -> True] because of a bug in the Graphics3D.m package definition for ListSurfacePlot3D which IS fixed in V2.1 The code leaves no optional pattern for options to pass on. If you do ListPlot3D then if you want to get the axes scaled properly you must set the MeshRange option. This is just set to be the min and max values in x and y. Thus if your data goes from -5 to 5 in both x and y you would do ListPlot3D[ data, MeshRange -> {{xmin, xmax}, {ymin, ymax}}] It needs this information since the first argument only contains the heights of the function. You can look at the output of Plot3D with InputForm to see exactly what the thing should look like. Tom Wickham-Jones WRI