cfdm.Field.nc_group_attributes¶
-
Field.
nc_group_attributes
(values=False)[source]¶ Returns properties to write as netCDF group attributes.
New in version (cfdm): 1.8.6
- Parameters
- Returns
dict
The selection of properties requested for writing to netCDF group attributes.
Examples
>>> f.nc_group_attributes() {'comment': None} >>> f.nc_set_group_attribute('foo') >>> f.nc_group_attributes() {'comment': None, 'foo': None} >>> f.nc_set_group_attribute('foo', 'bar') >>> f.nc_group_attributes() {'comment': None, 'foo': 'bar'} >>> f.nc_group_attributes(values=True) {'comment': 'forecast comment', 'foo': 'bar'} >>> f.nc_clear_group_attributes() {'comment': None, 'foo': 'bar'} >>> f.nc_group_attributes() {}