Project

General

Profile

pass indices of non-missing values to selindexbox?

Added by Christine Nam over 4 years ago

Anyone have an ideas how to identify the indices of non-missing values in a domain so that they can be passed into 'selindexbox' command?


Replies (3)

RE: pass indices of non-missing values to selindexbox? - Added by Ralf Mueller over 4 years ago

hi Christine!

you can use the operator outputkey - it offers a print-out of locations and their indices.

hth
ralf

RE: pass indices of non-missing values to selindexbox? - Added by Christine Nam over 4 years ago

Hi Ralf,
Can you provide an example?
My mask is simply composed of missing values and gtc,0 but when I use outputkey,lat I get the lat coordinates of the entire domain and not just that of the mask. I tried different combinations of ifthen, gtc, etc but everything returned lat of the whole domain.

Please and thank-you,
Chris.

RE: pass indices of non-missing values to selindexbox? - Added by Ralf Mueller over 4 years ago

I thought you could use something like

cdo -outputkey,lon,lat,xind,yind -selindexbox,1,4,5,9 -topo,r10x10 

but xind and yind seem to cover the range from 1 to gridsize. so it's not like a cartesian coordinate index or so. I was wrong I guess .... sorry

cheers
ralf

    (1-3/3)