cfdm.core.CoordinateConversion.set_domain_ancillaries

CoordinateConversion.set_domain_ancillaries(domain_ancillaries, copy=True)[source]

Set domain_ancillaries.

New in version (cfdm): 1.7.0

Parameters
domain_ancillaries: dict

Store the domain ancillaries from the dictionary supplied.

Parameter example:

domain_ancillaries={'earth_radius': 6371007}

copy: bool, optional

If False then any parameter values provided by the domain_ancillaries parameter are not copied before insertion. By default they are deep copied.

Returns

None

Examples:

>>> f = cfdm.core.CoordinateConversion()
>>> f.domain_ancillaries()
{}
>>> d = {'a': 'domainancillary0',
...      'b': 'domainancillary1',
...      'orog': 'domainancillary2'}
>>> f.set_domain_ancillaries(d)
>>> f.domain_ancillaries()
{'a': 'domainancillary0',
 'b': 'domainancillary1',
 'orog': 'domainancillary2'}
>>> old = f.clear_domain_ancillaries()
>>> f.domain_ancillaries()
{}
>>> old
{'a': 'domainancillary0',
 'b': 'domainancillary1',
 'orog': 'domainancillary2'}