[Thread Prev][Thread Next][Index]
[ferret_users] problem regridding data with repeat command
Hi Ferreters,
Im having issues using the repeat command while trying to concatenate a variable (take monthly datasets and make one year and then take each year dataset and make one entire record) and regrid it at the same time. I am trying to regrid dataset B to dataset A's grid where A is RCM data and B is SRB shortwave data. The command I use to concatenate the monthly data to one year is below:
repeat/range=1:12/name=m (define symbol imon = `m` ; if `m lt 10` then define symbol imon=0`m`; define symbol fname = srb_rel3.0_shortwave_monthly_utc_1985($imon).nc; set data ($fname); save/file=srb_1985SWI.nc/append SW_SFC_DN[l=1,g=srb2rcm]; cancel data ($fname) ; cancel memory )
where srb2rcm is defined above as:
define grid/like/x=GHU1/y=GHU1/l=GCH1/z=GCH1 srb2rcm
with both those axes (x/y and l/z) defined earlier by the input rcm and srb dataset, respectively.
This command works fine without the g=srb2rcm command added. However, I get the following error when trying to regrid at the same time:
LISTing to file srb_1985SWI.nc
**TMAP ERR: error in line definition
file coords dont match variable coords on axis LON
LIST/FORMAT=CDF/file=srb_1985SWI.nc/append SW_SFC_DN[l=1,g=srb2rcm]
Command file, command group, or REPEAT execution aborted
I think it has to do with the SRB data starting at x=i=0 longitude and the grid I want to regrid to starts at -15=x (15W) at i=0. Because if I remove the grid transformation in the repeat command and then regrid the final constructed dataset, it will work, but starts at 0E and ignores/cuts off all the SRB 15W to 0W data.
However, if I try to regrid each individual input dataset it works but is unfeasible to do each individually given all the input data. A bit at a loss as to why this can't be done or how I'm improperly doing it. Any suggestions would be great!
Thanks!
Marc
[Thread Prev][Thread Next][Index]
Contact Us
Dept of Commerce /
NOAA /
OAR /
PMEL /
Ferret
Privacy Policy | Disclaimer | Accessibility Statement