cf.AncillaryVariables.method

AncillaryVariables.method(name, *args, **kwargs)[source]

Return the results of a method applied to each field.

fl.method(name) is equivalent to fl.name().

Parameters:
name : str

The name of the method to apply to each element.

args, kwargs : optional

The arguments to be used in the call to the named method.

Returns:
out : cf.FieldList or cf.List

The results of the named method applied to each element.

See also

iter

Examples:
>>> fl.getprop('standard_name')
['air_temperature', 'eastward_wind']
>>> fl.method('getprop', 'standard_name')
['air_temperature', 'eastward_wind']
>>> fl.method('squeeze')
[None, None]

Previous topic

cf.AncillaryVariables.measures

Next topic

cf.AncillaryVariables.name

This Page