cf.gt

cf.gt(value, units=None, attr=None)[source]

Return a cf.Query object for a variable for being strictly greater than a value.

Parameters:
value : object

The value which a variable is to be compared with.

units : str or cf.Units, optional

The units of value. By default, the same units as the variable being tested are assumed, if applicable.

attr : str, optional

Return a query object for a variable’s attr attribute.

Returns:
out : cf.Query

The query object.

Examples:
>>> q = cf.gt(5)
>>> q
<CF Query: x gt 5>
>>> q.evaluate(6)
True
>>> q.evaluate(5)
False

Previous topic

cf.ge

Next topic

cf.le

This Page