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

Home » Public Forums » archive » plotting free form ascii data
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: plotting free form ascii data [message #25646 is a reply to message #25599] Thu, 05 July 2001 11:57 Go to previous messageGo to previous message
david[2] is currently offline  david[2]
Messages: 100
Registered: June 2001
Senior Member
Raphael Kudela (aka Patrick) writes:

> You are correct, my original problem was that the READ_ASCII function
> didn't like my file name. After I fixed that issue I tried passing the
> ascii data to the wv_applet function which controls the wavelet tookit.
> Since the previous post Ronn Kling noted that it is an add on package that
> I don't believe my department has the license for. No big deal really, what
> I am basically interested in is how to plot the data after it's been read
> by READ_ASCII? I don't believe I need the toolkit for this but I'm not
> experienced enough to be certain. The online help indicates the READ_ASCII
> places the data in a structure variable, which I assume does not need to be
> defined independently?

Well, I don't know how you defined your data file fields,
but suppose you had two columns of data and you named
the fields "pressure", and "temperature". Then the structure
that is returned from READ_ASCII has fields with these
two names:

IDL> Help, data, /Structure
** Structure <14248a0>, 2 tags, length=800, data length=800, refs=1:
TEMPERATURE FLOAT Array[100]
PRESSURE FLOAT Array[100]

You could plot the data like this:

IDL> Plot, data.temperature, data.pressure

Unfortunately, you won't know what name the data
fields were given, since you are allowing the user
to change them every time the data is read (a really
bad idea, IMHO). So you will have to resort to assuming
structure positions, like this:

IDL> Plot, data.(0), data.(1)

If it were me, I wouldn't be reading the data with
READ_ASCII. Or, at the very least, I wouldn't be
allowing the user to change the template every time.

But I think you really need a good IDL programming
book. As of this week, there are at least two good
ones. I'd search Amazon under "IDL Programming". Be
sure NOT to order any that have to do with the "Interface
Definition Language". You are looking for "Interactive
Data Language".

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Using C++ DLM's With IDL?
Next Topic: Question about tutorial in 1D Gaussian Filter

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

Current Time: Wed Oct 08 16:52:22 PDT 2025

Total time taken to generate the page: 0.00455 seconds