[ncl-talk] How to correctly read in the merged CMORPH data usig NCL

Barry Lynn barry.h.lynn at gmail.com
Tue May 2 08:45:14 MDT 2017


Hi:

This problem may be beyond my abilities (or really my familiarity).

Usually, when you read in data that doesn't match with other data you
expect, it means that
you are not reading the entire data set or simply not displaying it.

Can you verify to yourself that the data you read is the data you are
trying to plot (at least at certain
points)?

Regardless: if you are really getting no warnings or errors, then the
problem is most likely in the display.

Barry

On Sun, Apr 30, 2017 at 1:10 PM, 易路 <dg1225033 at smail.nju.edu.cn> wrote:

> Hi Bary,
>     Thanks very much for your attentions to my email. The script can run
> and no error messages were displayed during the script running, but the
> fianl out put picture  with the script written by myself (the upper one )
> is not the same with the picture applied by the offical web (the below
> one), the two pictures displayed the same data differed too much, and this
> indicated that the merged CMORPH data may be not correctly red in. I can't
> find the errors, so would you please help me to find the potential errors
> lying in the reading of the CMORPH data? With my great appreciations!
>      For the convenience to find out the problems, I upload the script
> "self.ncl" and its associated compassed  files "cnmap.rar" to plot the map,
> the emerged CMORPH data "1.grd" and its description file "1.ctl", to the
> accessory.  The cnmap.rar should be uncompassed by WinRAR and the folder
> shoul be added in the directory of "$NCARG_ROOT/lib/ncarg/nclscripts" to
> run the "self.ncl"
>  script.
>     Thanks a lot again for your attentions and your precious time!
>
> Best regards!
>
> Sincerely,
> Yi Lu
>
>
>
>
>
>
>
>
>
> 易路
>
> 南大邮件系统/学生/博士生/12级博士生
>
> 南京市汉口路22号
>
>
>
> ------------------ Original ------------------
> *From: * "Barry Lynn"<barry.h.lynn at gmail.com>;
> *Date: * Sun, Apr 30, 2017 12:15 PM
> *To: * "易路"<dg1225033 at smail.nju.edu.cn>;
> *Cc: * "ncl-talk"<ncl-talk at ucar.edu>;
> *Subject: * Re: [ncl-talk] How to correctly read in the merged CMORPH
> data usig NCL
>
> Hi Yi Lu:
>
> Could you please tell us the problem/error message.
>
> Thank you,
>
> Barry
>
> On Sun, Apr 30, 2017 at 7:07 AM, 易路 <dg1225033 at smail.nju.edu.cn> wrote:
>
>> Hi all,
>> I downloaed the merged CMORPH data from China Meteorological
>> Administration to get the hourly precipitation imformation, the suffix of
>> the data file is grd which is a standard format of the tool GrADS.
>> According to the associated ctl file of the grd file,  I tried to write the
>> NCL script to read it but can't get the right data, and I couldn't find out
>> the prolbems...
>>
>> So would you please help me to find out the problems ? Thanks very mcuh
>> for your precious time and kindness!
>>
>> Sincerely
>> Yi Lu
>>
>> ;;;;;;;;;;; the part of NCL script to read in the
>> precipitation ;;;;;;;;;;
>> tim = "1.grd"
>> setfileoption("bin","ReadByteOrder","LittleEndian")
>> rain = fbindirread(tim,0,(/nlat,nlon/),"double")
>>
>> nlat = 440
>> nlon = 700
>> r=new((/nlat,nlon/),"double")
>> k=0
>> do i  = 0, nlat-1
>>   do j = 0, nlon-1
>>    r(i,j) = rain(nlat-1-i,j)
>>         k = k+1
>>   end do
>> end do
>>
>> lon = fspan(70.05,139.95,nlon)
>> lon!0 = "lon"
>> lon at units = "degrees_east"
>> lon at long_name = "longitude"
>>
>> lat = fspan(15.05,58.95,nlat)
>> lat!0 = "lat"
>> lat at long_name = "latitude"
>> lat at units = "degrees_north"
>>
>> r!0 = "lat"
>> r!1 = "lon"
>> r&lat = lat
>> r&lon = lon
>> r at units = "mm/hour"
>> r at long_name = "merged CMORPH data "
>> r at _FillValue = -999.00
>> ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
>>
>>
>>
>>
>>
>>
>> 易路
>>
>> 南大邮件系统/学生/博士生/12级博士生
>>
>> 南京市汉口路22号
>>
>>
>> _______________________________________________
>> ncl-talk mailing list
>> ncl-talk at ucar.edu
>> List instructions, subscriber options, unsubscribe:
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>
>>
>
>
> --
> Barry H. Lynn, Ph.D
> Senior Lecturer,
> The Institute of the Earth Science,
> The Hebrew University of Jerusalem,
> Givat Ram, Jerusalem 91904, Israel
> Tel: 972 547 231 170
> Fax: (972)-25662581
>
> C.E.O, Weather It Is, LTD
> Weather and Climate Focus
> http://weather-it-is.com
> Jerusalem, Israel
> Local: 02 930 9525
> Cell: 054 7 231 170
> Int-IS: x972 2 930 9525
> US 914 432 3108 <(914)%20432-3108>
>



-- 
Barry H. Lynn, Ph.D
Senior Lecturer,
The Institute of the Earth Science,
The Hebrew University of Jerusalem,
Givat Ram, Jerusalem 91904, Israel
Tel: 972 547 231 170
Fax: (972)-25662581

C.E.O, Weather It Is, LTD
Weather and Climate Focus
http://weather-it-is.com
Jerusalem, Israel
Local: 02 930 9525
Cell: 054 7 231 170
Int-IS: x972 2 930 9525
US 914 432 3108
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170502/2ae134a0/attachment-0001.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 06DAF9DF at 67563827.27B80559.gif
Type: image/gif
Size: 218618 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170502/2ae134a0/attachment-0001.gif 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 3CA042CF at 7660B63C.27B80559.png
Type: application/octet-stream
Size: 81403 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170502/2ae134a0/attachment-0001.obj 


More information about the ncl-talk mailing list