[Thread Prev][Thread Next][Index]

Re: [ferret_users] reading sequence of files



Hi -
If there is just one variable in the files, and assuming they are netCDF files, you can use Ferret's capabilities for getting dataset attributes to find the variable names.

http://ferret.pmel.noaa.gov/Ferret/documentation/users-guide/variables-xpressions/VARIABLES#_VPINDEXENTRY_attrib_keywords

So, put something along these lines in a script,

 use "$1"
 let vnames = ..varnames
 let tempvar = `vnames[i=1]`

  ...  ! whatever commands you want, using variable tempvar

 cancel data/all

and then you can call this script for each dataset.

On 11/11/2010 10:29 PM, STEEVEN PAUL YERRAGUNTLA wrote:
Dear ferreters,
         I wanted to make a generalized script which executes the  sequence of data files having different variables, for instance one file having var SST other having var AIRT etc. As we know we can call dataset attributes  in the executing script using `SST,return=lend` , `AIRT, return=dset` etc. Is there any provision in ferret to call the variable name without mentioning directly.
I  gone through the weblink showing how to read sequence of datafiles which presumes the variable in common.
http://www.pmel.noaa.gov/maillists/tmap/ferret_users/fu_2006/msg00339.html

Thanks in advance,


--
Steeven Paul Y
Research Fellow
National Institute of Oceanography
Regional Center Visakapatnam (RCW)
INDIA.



[Thread Prev][Thread Next][Index]

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

Privacy Policy | Disclaimer | Accessibility Statement