[Thread Prev][Thread Next][Index]

Re: [ferret_users] index question

Hi Peng,
The coordinates, longitudes and latitudes, can be accessed as the coordinate varaibles x[gx=var], y[gy=var]. These are called "Pseudo-variables" in the documentation.

So, continuing your script, the longitude where the maximum is reached, is

  let lon_of_imx = x[gx=dd2,i=`i_of_imx`]

and since in this example, there is just one latitude,

  let lat_of_imx = y[gy=dd2]


Ge Peng wrote:
Hi All,

I have two data sets containing
lon,lat, and data for some variable. All three fields have
i=1:35,j=1,k=1,l=1:9200 dimensions.

I first find along i-axis maximum of variance between the two datasets:

let dd2 = (data[d=1]-data[d=2])^2
let dd2_imx=dd2[i=@max]
let zero_at_imx=dd2-dd2_imx
let i_of_imx = zero_at_imx[i=@loc:0]

Now I would like to get
lon(i_of_imx), lat(i_of_imx) for non-zero dd2_imx.

It should be straight forward but it is not transparent to me.

Please help.


--- Peng

[Thread Prev][Thread Next][Index]

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

Privacy Policy | Disclaimer | Accessibility Statement