[ncl-talk] How to read ascii data and subscript a three dimension arry

Black, Forrest (LARC-D318)[UNIVERSITIES SPACE RESEARCH ASSOCIATION] forrest.black at nasa.gov
Thu Oct 20 07:29:11 MDT 2016


Hi Tao,

The attached script reads in asci data and creates a new table by column, but gives you an idea how the NCL asciiread function works.
Once the date column is read you can use the str_split function to split up your date in NCL (https://www.ncl.ucar.edu/Document/Functions/Built-in/str_split.shtml).

I hope this helps,


-        Forrest

From: ncl-talk-bounces at ucar.edu [mailto:ncl-talk-bounces at ucar.edu] On Behalf Of Tao Lu
Sent: Thursday, October 20, 2016 3:35 AM
To: ncl-talk at ucar.edu
Subject: [ncl-talk] How to read ascii data and subscript a three dimension arry

Hello ncl-talk

I am Tao.

I have a time series data. I want to use this data to plot a contour graph.
[Inline image 1]
As you see, I get the data in this format. This data is rain data of 100x100 grid with different time.
How can I make an array rain(ntime, nlat, nlon) from this data?

Please help me, thanks in advance.


--

******************************************************
Tao Lu    (M. Eng)
Laboratory of River Engineering and Hydrology,
Dept. of Civil and Environmental Engineering,
Graduate School of Science and Engineering,
Chuo University

1-13-27,Kasuga,Bunkyo-ku,Tokyo
112-8551, Japan
TEL: 03-3817-1805;   Phone: 070-2188-7509
Email1: hakufu.asano at gmail.com<mailto:mail%3Amet.yamos at gmail.com>
Email2: lutao at civil.chuo-u.ac.jp<mailto:mail%3Ayamoto at civil.chuo-u.ac.jp>
*****************************************************
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20161020/779b443d/attachment-0001.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image002.png
Type: image/png
Size: 202361 bytes
Desc: image002.png
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20161020/779b443d/attachment-0001.png 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: write_data.ncl
Type: application/octet-stream
Size: 964 bytes
Desc: write_data.ncl
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20161020/779b443d/attachment-0001.obj 


More information about the ncl-talk mailing list