is.inrange: Check whether argument is within range

is.inrangeR Documentation

Check whether argument is within range

Description

Check whether argument x is within range.

Usage

is.inrange( x, range=c(0,1) )

Arguments

x

numerical value(s) to be evaluated.

range

list of two numbers defining the range used in the evaluation of x.

Details

The return value indicates whether x is an element of [range[1], range[2]].

Note that the range used in the evaluation includes both endpoints of the specified range.

Value

Logical.

See Also

range.

Examples

is.inrange(1/2)
is.inrange(pi, range=c(0,pi))

hqmisc documentation built on May 9, 2022, 5:08 p.m.

Related to is.inrange in hqmisc...