If I recall, the .general format imports things as a group, each one of
which has a single "data" component. So you'll have to do something
slightly more complicated (but not much!)
Use "Select" to select the member of the group you want (the one that has
either the "x" or "y" data you want). Depending on how it was imported, it
may be "labeled" with this field name or not; use Print to look at it and
see if the member has a name or just an index.
Once you've selected your two things (they will each be a field), use
Extract to extract the "data" components. That's the default. Now run the
ones you want for "x" into the first input of Construct, and the ones you
want for "y" into the last (fourth) input of Construct. This is now
plottable. What Construct does is put your two lists of values into a new
field, with the x's as the positions and the y's as the data. I forget; you
may be able to skip the Extract step; Construct may just extract the "data"
component itself.
Donna L. Gresh, Ph.D.
Optimization and Mathematical Software Group
IBM T.J. Watson Research Center
(914) 945-2472
http://www.research.ibm.com/people/g/donnagresh
[EMAIL PROTECTED]
Owen Matthews
<[EMAIL PROTECTED]> To:
[email protected]
Sent by: cc:
[EMAIL PROTECTED] Subject: Re: [opendx-users]
Plotting
son.ibm.com
03/24/2003 08:52 AM
Please respond to
opendx-users
On Thu, 13 Mar 2003, Nils Smeds wrote:
>
> >
> > I have a set of data which is written out in 'general' format. What I
> > would like to do is plot the data as a graph. I can do this fine and
can
> > select the y variable I want but I can only plot against 'position' in
x.
> > Is there a way I can select the x variable?
> >
> > Thanks a lot
> > Owen.
>
> I belive the "Rename" module is your friend. Rename your x-variable of
> your choice to be the positions component.
>
> /Nils
>
Thanks Nils, this seems like a good idea.
I have tried this but am not getting good results. What I am doing
precisiely is this: I am importing my data in .general format. I then
attempt to use the rename module to change the name of a variable of my
choice to "positions". I use a selector to choose the variable to be
replaced. However, whichever variable I choose I get this error: ERROR:
Rename: Missing data: input is not a field, or has no x component. (or
whatever component is selected.) The components clearly do exist because
the selector recognises them. Can anyone tell me what I am doing wrong, or
give me another solution to my original problem?
Cheers
Owen.
--
******************************************************
------>Please note my new email address below!!<------
------------------------------------------------------
Owen Matthews
Theoretical Astrophysics Tel: +44 (0)116 2522084
University of Leicester Fax: +44 (0)116 2522070
University Road
Leicester [EMAIL PROTECTED]
LE1 7RH
------------------------------------------------------
http://www.astro.le.ac.uk/~owm
******************************************************