The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Inactive » comp.soft-sys.math.mathematica

Notice: We are no longer accepting new posts, but the forums will continue to be readable.

Topic: How to plot a date file? Some questions, some solutions.
Replies: 1   Last Post: Sep 26, 1996 9:58 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]

Posts: 17
Registered: 12/7/04
How to plot a date file? Some questions, some solutions.
Posted: Sep 23, 1996 10:17 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

The following is a file that I want to plot
as either R versus FQ or DG versus FQ.
Note it has three columns of numbers preceeded
by two letter identifiers R_, DG, FQ, where
R_ is a two letter identifier. _ denotes
white space.

R 999.1E-3,DG 000.0E+0,FQ 1.000E+3
R 999.1E-3,DG 000.0E+0,FQ 1.023E+3
R 999.1E-3,DG 000.0E+0,FQ 1.047E+3
R 999.1E-3,DG 000.0E+0,FQ 1.072E+3
R 999.1E-3,DG 000.0E+0,FQ 1.096E+3
R 999.1E-3,DG 000.0E+0,FQ 1.122E+3
R 999.1E-3,DG 000.0E+0,FQ 1.148E+3
R 999.1E-3,DG 000.0E+0,FQ 1.175E+3
R 999.1E-3,DG 000.0E+0,FQ 1.202E+3
R 999.1E-3,DG 000.0E+0,FQ 1.230E+3
R 998.9E-3,DG 000.0E+0,FQ 7.244E+3
R 998.9E-3,DG 000.0E+0,FQ 7.413E+3
R 999.0E-3,DG 000.0E+0,FQ 7.585E+3
R 998.9E-3,DG 000.0E+0,FQ 7.762E+3
R 998.9E-3,DG 000.0E+0,FQ 7.943E+3
R 998.9E-3,DG 000.0E+0,FQ 8.128E+3
R 999.0E-3,DG 000.0E+0,FQ 8.317E+3
R 999.0E-3,DG 000.0E+0,FQ 8.511E+3
R 999.0E-3,DG 000.0E+0,FQ 8.709E+3
R 999.0E-3,DG 000.0E+0,FQ 8.912E+3
R 999.0E-3,DG 000.0E+0,FQ 9.120E+3
R 999.0E-3,DG 000.0E+0,FQ 9.332E+3
R 998.8E-3,DG-000.0E+0,FQ 9.999E+3
R 998.8E-3,DG-000.0E+0,FQ 10.00E+3

The format is consistent. There is no space between a two letter
identifier and the number.

R followed by a space, then an optional sign, ie - for minus or
space for plus. The number part is 4 digit and one decimal sign.
The Exponent is one digit with a mandatory sign, then a comma separator,
and next two letter identifier DG, followed by no space and
so on.

The first problem is to separate the list into three columns
and ignoring


This is done by the following ReadList command.

a=ReadList["c:\\file", Word,
WordSeparators -> {"R", ",DG", ",FQ"},

For RecordList -> True, see page 182,
For WordSeparators -> {}, see p 496,

This has one PROBLEM. Although all the three number fields are separated,
they are not numbers any more, but words.

The second problem is to get any two columns from the three columns so that
they can be plotted using


command. I do not see how to directly get two columns other than transposing
getting the rows, and then transposing back again, ie


Can some kind soul help? Pls reply via email also.
Thanks a lot!

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2018. All Rights Reserved.