[Thread Prev][Thread Next][Index]

Re: spatial average


	Ferret is doing exactly what you want. The structure
my_var[x=@ave,y=@ave] will give you a mean value over the whole region
excluding points identified as BAD or MISSING. An additional note, the @AVE
transformation provides a grid box size weighted average. Therefor (for
example), if your grid is on longitude and latitude, the decreasing width (in
longitude) will be taken into account as you move away from the equator -
giving you a true spatial average. If you do not want a weighted average, then
you can calculate an unweighted average with the command:

yes? let southuw=my_var[x=@sum,y=@sum]/my_var[x=@ngd,y=@ngd]

and southuw will be the grid box average value.

	Regards, Mark

On Dec 4, 12:35pm, Antonio Caetano Vaz Caltabiano wrote:
> Subject: spatial average
> Dear ferreters
> I have some problems.
> 1. I want to calculate spatial averages, I mean, one mean value for a whole
> region. My data has 204 point on the L index. I've used the commands below:
> yes? set data my_data
> yes? set region/x=50w:10e/y=0:10n
> yes? let south=my_var[x=@ave,y=@ave]
> Ferret gave me a time serie as I expected. But, does anyone know if the
> above are correct?? Did Ferret make what I want??
> 2. Another doubt: I set -999 value over land. If the commands above are
> when Ferret calculates the spatial average, does Ferret automatically
> that -999 is a bad value and it does not use them to calculate the average??
> not, what can I do to make that Ferret recognizes them as a bad value??

 Mark Verschell                     NASA/Goddard Space Flight Center
 verschell@neptune.gsfc.nasa.gov    Code 970/Lab. for Hydrospheric Proc.
 301-614-5669  Fax: 301-614-5666    Greenbelt, MD 20771

                  USQC Certified: 100% Microsoft Free

[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP

Contact Us | Privacy Policy | Disclaimer | Accessibility Statement