Re: 3d graph

*To*: mathgroup at smc.vnet.net*Subject*: [mg3095] Re: [mg3054] 3d graph*From*: penny at edu-suu-scf.sc.suu.edu (Des Penny)*Date*: Wed, 31 Jan 1996 03:04:35 -0500*Sender*: owner-wri-mathgroup at wri.com

>Hey, > >I have what may be a very simple question but I have just >started using Mathematica and can not figure it out. I have >a text file with lines of x y z values seperated by tabs, ie > >223.3 233.5 2894.0 > >How do I get a 3d graph of the points? I would appreciate any help >or a location in the Stephen Wolfram book that explains this. I have tried >various functions ListPlot3D, Graphics3D but they either don't >work or give me a surface that I know does not match the data. I >can read the data from the file correctly. At least I think I have it >in a proper format. I use > >pointlist=ReadList["weights.txt",{Number,Number,Number}]; > >Which give me a list that looks like this > >{{-20., -20., 68272.796875}, {-19., -20., 67817.}, > > {-18., -20., 67363.203125}, {-17., -20., 66911.398438}, > > {-16., -20., 66461.601563}, {-15., -20., 66013.796875}, > >thanks, >Stephen Nichols Hi: This is an addendum to Dave Wagner's suggestion on this (cf [mg3059]). The following will also work: data={{1,2,3}, {2,3,1},{3,2,-1},{4,5,3},{1,5,-2},{3,-2,4}}; pts=Map[Point,data]; Show[Graphics3D[{PointSize[0.02],pts}], Axes->True, AxesLabel->{"x","y","z"}]; Another possible problem is that your sample data above has some scaling problems in that the z data will dominate the x and y data. Hope this helps, Cheers, Des Penny ========================== Des Penny Physical Science Dept. Southern Utah University Cedar City, UT 84720 VOICE: (Office): (801) 586-7708 (Home) : (801) 586-2286 FAX: (801) 865-8051 e-mail: penny at suu.edu ========================== ==== [MESSAGE SEPARATOR] ====