cf.Field.allclose

Field.allclose(y, rtol=None, atol=None)[source]

Returns True if two broadcastable fields have have equal array values to within numerical tolerance, False otherwise.

The follwowing are accounted for:

  • Units
  • Axis order
  • Axis direction
Parameters :

y :

atol : float, optional

The absolute tolerance for all numerical comparisons, By default the value returned by the cf.ATOL function is used.

rtol : float, optional

The relative tolerance for all numerical comparisons, By default the value returned by the cf.RTOL function is used.

Returns :
out : bool

Whether or not the two fields’ data arrays are equivalent.

See also

equals

Examples

Previous topic

cf.Field.year

Next topic

cf.Field.anchor

This Page