[Thread Prev][Thread Next][Index]

Re: [ferret_users] defining common time axis for 2 datasets with different origin/end



Hi Francois,
I think that Xeuben captured the issue when he noticed that one of your original monthly time axes is defined with coordinates at the edges of the months, and the other at mid-month. Your output time axis has values near the edges of months. Regridding is done based on the grid cells of the axes, not on the location of the coordinates (which generally lie in the center of each grid cell).

When you define this output axis,
define axis/t="1-jan-1951":"31-dec-2006":30.436875/units=day axd
the first grid cell starts in mid-December 1950 and ends in mid-January 1951. If the first point of the axis in dataset D2 were within the time range, you would get a result from your original regridding request. I am guessing that the first coordinate of that axis falls just after the end of that grid cell, (for instance maybe the output grid cell ends at 16-JAN-1951:00:00 and the coordinate of D2 is at 16-JAN-1951 12:00) and so its value contributes to the next month's value in the interpolation onto the new time axis.

The default method of regridding is linear interpolation.  See http://ferret.pmel.noaa.gov/Ferret/documentation/users-guide/Grids-Regions/GRIDS#Chapter4-Regridding. Also have a look at this FAQ, which talks about regridding by averaging: How can I determine the averaging weights when regridding with @AVE?

Regridding by interpolation does not put a result into an output time axis where the coordinate value of the input time axis lies outside the output-axis grid box.  Interpolation by averaging does, however. If you try your original command but with
let p1 = pm[d=D1, gt=gtd@AVE]
let p2 = pm[d=D2, gt=gtd@AVE]

    I think you will see a result at that first time step

So, you need to decide what the output time axis should look like, and choose a regridding method that seems correct for what you know about how the input monthly axes were computed, and how you think the result is best computed.

Ansley


On 12/1/2010 2:56 PM, Xuebin.Zhang@xxxxxxxx wrote:
Francois, 

   The second dataset starts at 16-Jan-1951, but the starting point of the new time axis "gtd" is 1-jan-1951, so the first data point should be "missing" after regridding (let p2 = pm[d=D2, gt=gtd]). The reason is that FERRET doesn't know how to extrapolate.   

   One simple solution is that you can just regrid dataset 1 onto dataset 2, i.e., 
   Let p1= pm[d=D1, gt=pm[d=2]]
   
   One more thing is that, data points are located in the beginning of each month for the first dataset, while in the middle for the second dataset. Since they are all monthly datasets, you may want to align them to the middle of month. For this purpose, you may use the "@asn" transformation. Basically, you have to get a subset of first dataset for the period 1951-2006, then associate this subset to a common grid with @asn transformation (without interpolation). 
   For your reference.
   
Xuebin

-----Original Message-----
From: owner-ferret_users@xxxxxxxx [mailto:owner-ferret_users@xxxxxxxx] On Behalf Of DELCLAUX Francois
Sent: Wednesday, 1 December 2010 7:37 PM
To: ferret_users@xxxxxxxx
Subject: [ferret_users] defining common time axis for 2 datasets with different origin/end

Hi Ferret users,

I would like to compare (bias and correlation maps) 2 monthly 
precipitation datasets.

The first one, D1, starts on 1rst january 1901 and ends on 1rst december 
2006, so 106 years and 1272 months: L varies from 1 to 1272
  01-JAN-1901 /    1:    60.
  31-JAN-1901 /    2:    10.
  03-MAR-1901 /    3:    31.
....
  01-OCT-2006 / 1270:    88.
  01-NOV-2006 / 1271:     9.
  01-DEC-2006 / 1272:    16.


The second one, D2, starts at 16 jan 1951 and ends at 16 december 2007, 
so 57 years and 684 values: L varies from 1 to 684
  16-JAN-1951 /   1:   21.4
  15-FEB-1951 /   2:    3.3
  18-MAR-1951 /   3:    7.0
...
  16-OCT-2007 / 682:   42.4
  16-NOV-2007 / 683:    2.3
  16-DEC-2007 / 684:    0.0

In order to compare D1 and D2 over the same period, I defined a common 
time axis/grid over 1951-2006 period such as :
define axis/t="1-jan-1951":"31-dec-2006":30.436875/units=day axd ; 
define grid/t=axd gtd
and regrid the two datasets on this axis.

let p1 = pm[d=D1, gt=gtd]
let p2 = pm[d=D2, gt=gtd]

But when I list these new variables on one point new datasets, I have 
the following output:
                      P1     P2
01-JAN-1951 /   1:    4.0   ....
31-JAN-1951 /   2:   36.5   12.3
02-MAR-1951 /   3:   33.2    5.1
...
31-OCT-2006 / 671:   11.2   11.3
01-DEC-2006 / 672:   16.8    9.1
31-DEC-2006 / 673:   ....    8.7

Consequently, it's impossible to compare these 2 regridded datasets.
Then, how can I define the correct time axis (i.e. identical L values)  
wich will give consistent regrided datasets ?

Thanks in advance.


[Thread Prev][Thread Next][Index]

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

Privacy Policy | Disclaimer | Accessibility Statement