[Thread Prev][Thread Next][Index]

Re: [ferret_users] Regridding 20 year time axis



Apologies - the "tax_jday=tjday" is a typo - the axis is defined using jday (....just in case anyone thought this might explain the issue!)

P


On Jan 9, 2009, at 4:49 PM, Paul Young wrote:

Dear ferret users,

I am having problems regridding the time axis of a 20 year time series of monthly mean model output. Here's what I am doing:

yes? use my_Z_data_20yr.nc

!Read in data containing Julian day values for 20 years on a "noleap" calendar 
yes? file/variable=jday/columns=12/type=numeric "20year_axis.dat" 

!Define new time axis
yes? define axis/t0=31-Dec-2000/from_data/units=days/calendar=noleap tax_jday=tjday

!Regrid original variable to tax_jday
yes? let new_var = old_var[gt=tax_jday@asn]

!Save new variable (using Jaison Kurian's memory tricks)
yes? let l_start = `new_var,r=lstart` 
        yes? let l_end = `new_var,r=lend` 
yes? let slices = l_end - l_start + 1 
yes? REPEAT/L=`l_start`:`l_end`:1 (;\ 
save/file="my_outfile.nc"/append/quiet new_var ; \
say " Time slice `(L-l_start+1)`/`slices`" ;\ 
)

I then get the following error message:

!-> REPEAT: L=1 
**TMAP ERR: error in line definition 
disordered output coordinate value: 15.500 Axis: TAX 
LIST/FORMAT=CDF/file="my_outfile.nc"/append/quiet new_var
Command file, command group, or REPEAT execution aborted

(I'm guessing TAX is a truncation of tax_jday?). 

Just to confirm that the old and new time axes are of the same size:

yes? show axis time 
name   axis   # pts      start   end 
TIME   TIME   240 i      01-FEB-2001 00:00   01-JAN-2021 00:00 
T0 = 01-SEP-2000 00:00:00 
CALENDAR = NOLEAP 
Axis span (to cell edges) = 7300

yes? show axis tax_jday
  name      axis    # pts      start     end
   TAX_JDAY  TIME    240 i      15-JAN-2001 12:00    15-DEC-2020 12:00
T0 = 31-DEC-2000
CALENDAR = NOLEAP
   Axis span (to cell edges) = 7299

A related question: Is there a way to generate tax_jday in ferret, rather than read it in? I thought about adding multiples of 365 to an array of mid month, Julian day values (midmonth = {15.5, 45.0, 74.5, 105.0, 135.5, 166.0, 196.5, 227.5, 258.0, 288.5, 319.0, 349.5}) to get the 240 element array, but I couldn't think how to do it in ferret. Is it possible to concatenate user defined arrays into one variable (e.g. like let big_array={array1,array2,....,arrayN})? I don't have XCAT etc on my version of ferret, though I guess that might be the solution....

Thanks for any help,

Paul


-----
Paul Young

Chemistry and Climate Processes
Chemical Sciences Division
NOAA Earth System Research Laboratory
325 Broadway R/CSD8
Boulder CO 80305-3328
USA

Tel:   +1 303-497-4943
Fax:   +1 303-497-5686



-----
Paul Young

Chemistry and Climate Processes
Chemical Sciences Division
NOAA Earth System Research Laboratory
325 Broadway R/CSD8
Boulder CO 80305-3328
USA

Tel:   +1 303-497-4943
Fax:   +1 303-497-5686


[Thread Prev][Thread Next][Index]

Contact Us
Dept of Commerce / NOAA / OAR / PMEL / TMAP

Privacy Policy | Disclaimer | Accessibility Statement