Builds a comparison operator for use inside attribute functions such as age, valueAsNumber, startDate, etc. Accepts integer, numeric, or Date inputs; returns the matching opAttribute type.

lte(x)

# S4 method for integer
lte(x)

# S4 method for numeric
lte(x)

# S4 method for Date
lte(x)

Arguments

x

Comparison bound (integer, numeric, or Date).

Value

An opAttribute for use inside attribute constructor functions.

See also

lt, gt, gte, eq, bt

Examples

# Age 65 or younger
conditionOccurrence(cs(1L, name = "test"), age(lte(65L)))
#> <Capr ConditionOccurrence Query> test