Re: GPCP 1dd binary read

From: Dennis Shea <shea_at_nyahnyahspammersnyahnyah>
Date: Mon, 26 Nov 2007 19:06:38 -0700

Hi Saji,

My experience with the GPCP 1DD [DD=Daily Data] binary files
is that they have no missing gaps. The documentation at:

     http://www1.ncdc.noaa.gov/pub/data/gpcp/1dd/doc/1DD_doc

states

"Each monthly file consists of a 1440-byte header record
  containing ASCII characters (which is the same size as
  one row of data), then a month (28, 29, 30, or 31) of
  daily grids of size 360x180 containing REAL*4 values.
  The header line makes the file nearly self-documenting,
  in particular spelling out the variable and version names,
  and giving the units of the variable. The header line may
  be read with standard text editor tools or dumped under
  program control. All the month's days of data are present,
  even if some have no valid data. Grid boxes without valid
  data are filled with the (REAL*4) "missing" value -99999.
  The data may be read with standard data-display tools (after
  skipping the 1440-byte header) or dumped under program control."

Saji Njarackalazhikam Hameed wrote:
> Hi Prince,
>
> Greetings from Korea (how r things?).
>
> There is the possibility that the first record is empty. GPCP data may have
> data gaps. You may have to catch those. I do the following (my data is monthly
> mean data though).
>
> ;--------------%< code
>
> setfileoption("bin","ReadByteOrder","BigEndian")
>
>
> iyrec=0
> do iyr = yr1,yr2
> infile="gpcp_v2_psg."+iyr
> irec=1
> do imon=1,nmon
> do j = 1,nlat
> prec(iyrec,j-1,:) = fbindirread(infile, irec, nlon, "float")
> irec=irec+1
> end do
> if all(ismissing(prec(iyrec,:,:)))
> print("All Missing Values during month "+imon)
> break
> end if
> iyrec=iyrec+1
> end do
> end do
> ;--------------%< code
>
> saji
> ...
>
> * Prince K. XAVIER <xavier_at_lmd.ens.fr> [2007-11-26 17:59:42 +0100]:
>
>> Hi all,
>>
>> I am trying to read the GPCP 1DD data at
>> http://www1.ncdc.noaa.gov/pub/data/gpcp/1dd/data/
>> using the options:
>>
>> setfileoption("bin","ReadByteOrder","BigEndian")
>> prec = fbindirread("gpcp_1dd_p1d.199707",1,(/180,360/),"float")
>>
>> But I find get the first record empty. I think I am doing something wrong
>> with the record length. If someone has read this data using NCL, could you
>> help to set the correct file options?
>>
>> thanks in advance
>> Prince
>>
>> --
>> Prince K. XAVIER
>> Laboratoire de Meteorologie Dynamique
>> Ecole Normale Superieure
>> 24 Rue Lhomond 75231 Paris cedex 05 FRANCE
>> Tel: +33 (0)1 44 32 22 32
>> Fax: +33 (0)1 43 36 83 92
>>
>> _______________________________________________
>> ncl-talk mailing list
>> ncl-talk_at_ucar.edu
>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>

_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Mon Nov 26 2007 - 19:06:38 MST

This archive was generated by hypermail 2.2.0 : Tue Nov 27 2007 - 07:07:11 MST