Re: question about using readAsciiTable

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Thu, 16 Oct 2008 15:11:10 -0600 (MDT)

On Thu, 16 Oct 2008 caoyan_at_cma.gov.cn wrote:

> hi,
>
> I use readAsciiTable to read a ASCII file, In this file,some line have 17 colomns,some line have less, I just want read the first 3 column of each line, how should I specify the parameter of readAsciiTable.
>
> thanks
>
> caoyan

Hi Caoyan,

The readAsciiTable function wants its data nice and organized; that
is, it doesn't want varying numbers of columns.

NCL's ascii reading functions won't do very well on a file like yours.
If your columns of data are at least lined up, then you can use the
NCL "system" command in conjunction with the Unix "cut" command to cut
out the columns you're interested in.

Please see:

   http://www.ncl.ucar.edu/Applications/ascii_cut.shtml

for an example.

If this doesn't work for you, then can you send me a sample data
file?

--Mary

_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Thu Oct 16 2008 - 15:11:10 MDT

This archive was generated by hypermail 2.2.0 : Fri Oct 17 2008 - 10:06:33 MDT