ToBeReviewed/INIT/
initncdf.pro
Initfile for Netcdf file. define all the grid parameters
initncdf
initncdf, ncfilein, XAXISNAME=string, YAXISNAME=string, ZAXISNAME=string, MASKNAME=string, INVMASK=INVMASK, USEASMASK=string, MISSING_VALUE=MISSING_VALUE, START1=START1, XYINDEX=XYINDEX, ZINDEX=ZINDEX, _EXTRA=_EXTRA
Parameters
ncfilein
in
required
type: string
A string giving the name of the NetCdf file
Keywords
XAXISNAME
type: string
default: 'x', 'longitude', 'nav_lon' or 'lon'
A string giving the name of the variable in the file
that contains the [xyz]axis.
YAXISNAME
type: string
default: 'y', 'latitude', 'nav_lat' or 'lat'
A string giving the name of the variable in the file
that contains the [xyz]axis.
ZAXISNAME
type: string
default: 'z', 'level', 'lev', 'depth...'
A string giving the name of the variable in the file
that contains the [xyz]axis.
MASKNAME
type: string
A string giving the name of the variable in the file
that contains the land/sea mask
INVMASK
To inverse the mask: mask = 1-mask
USEASMASK
type: string
A string giving the name of the variable in the file
that will be used to build the land/sea mask. In this case the
mask is based on the first record (if record dimension
exists). The mask is build according to :
1 the keyword missing_value if existing
2 the attribute 'missing_value' if existing
3 NaN values if existing
MISSING_VALUE
To define (or redefine if the attribute is
already existing) the missing values used with USEASMASK
keyword
START1
Index the axis from 1 instead of 0 when using
/xyindex and/or zindex
XYINDEX
To define the x/y axis with index instead of using
the values contained in X/YAXISNAME.
x/yaxis = keyword_set(start1) + findgen(jpi/jpj)
this forces key_onearth = 0
ZINDEX
To define the z axis with index instead of using
the values contained in ZAXISNAME.
zaxis = keyword_set(start1) + findgen(jpk)
_EXTRA
Used to pass your keywords/
Examples
IDL> initncdf,'toto.nc',glam=[-180,180]
Version history
Version
$Id: initncdf.pro 157 2006-08-21 09:01:50Z navarro $
History
Sebastien Masson (smasson@lodyc.jussieu.fr)
8 May 2002
Known issues
Restrictions
Change the grid parameters of the common.pro
the file must contain an x and an y axis. (1 ou 2 dimentional array)
Other attributes
Uses routines
common.pro
Produced by IDLdoc 2.0 on Tue Aug 29 14:50:00 2006.