comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » 3d displaying with x=longitude, y=latitude, z=altitude, but not yet working (T_T)
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
3d displaying with x=longitude, y=latitude, z=altitude, but not yet working (T_T) [message #53754] Wed, 02 May 2007 05:57 Go to previous message
kim20026 is currently offline  kim20026
Messages: 54
Registered: November 2006
Member
Good day, everyone. I would like to ask a question on 3d displaying.

I have this data file.

dat1.txt:
Sokcho 38.2500 128.5667 17.8
Cheorwon 38.1500 127.3000 154.2
Dongducheon 37.9000 127.0667 112.5
Daeguallyeong 37.6833 128.7667 842.5
Chuncheon 37.9000 127.7333 76.8

I read this file as follows.
readcol, 'dat1.txt', city, lat, lon, alt, format = 'A, 3F'

And then I am going to display these data into 3d.
x = lon,
y = lat,
z = alt

Based on the a procedure on www.dfanning.com, I tried this way below
but the results was not what I wanted to. Is there anyone to help
me?

Harry

------------------------------------------------------------ -----------------------
PRO SCATTER3D_altitude

; Read the data file.

readcol, 'dat1.txt', city, lat, lon, alt, format='A, 3F7.2'
n=n_elements(lat)

vsym, 24 , /fill

; Load a color table and create colors for the scatterplot.

LOADCT, 38, NCOLORS=!D.N_COLORS-1
TVLCT, 70, 70, 70, !D.N_COLORS-1
zcolors = BYTSCL(alt, TOP=!D.N_COLORS-2)

; Set the 3D coordinate space with axes.

SURFACE, DIST(5), /NODATA, /SAVE, XRANGE=[125,132], $
YRANGE=[33,39], ZRANGE=[0, 900], CHARSIZE=1.5, COLOR=!D.N_COLORS-2,
BACKGROUND=!D.N_COLORS-1, $

; Plot the random points in 3D space with a diamond shape.

PLOTS, lon, lat, alt, PSYM=4, COLOR=zcolors, /T3D

; Connect the data points to the XY plane of the plot.

FOR j=0, n-1 DO PLOTS, [lon(j), lon(j)], [lat(j), lat(j)], [0,
alt(j)], COLOR=zcolors(j), /T3D

END
[Message index]
 
Read Message
Read Message
Previous Topic: Re: 3d displaying with x=longitude, y=latitude, z=altitude, but not yet working (T_T)
Next Topic: HISTOGRAM and string data

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 12:24:39 PDT 2025

Total time taken to generate the page: 1.03978 seconds