cdms2.dataset:CdmsFile¶
-
CdmsFile.
createVariableCopy
(self, var, id=None, attributes=None, axes=None, extbounds=None, extend=0, fill_value=None, index=None, newname=None, grid=None)[source]¶ Define a new variable, with the same axes and attributes as in <var>.
- Parameters
- varvariable to copy (cdms2.tvariable.TransientVariable or cdms2.fvariable.FileVariable)
- attributesA dictionary of attributes. Default is var.attributes.
- axesThe list of axis objects. Default is var.getAxisList()
- extboundsBounds of the (portion of) the extended dimension being written.
- id or newnameString identifier of the new variable.
- extend :
1 define the first dimension as the unlimited dimension.
- 0 do not define an unlimited dimension. The default is the define
the first dimension as unlimited only if it is a time dimension.
- fill_valueThe missing value flag.
- indexThe extended dimension index for writting. The default index is determined
by lookup relative to the existing extended dimension.
- gridThe variable grid. none the value of var.getGrid() will used.
- Returns
- file variable (cdms2.fvariable.FileVariable)