between {poorman}R Documentation

Do values in a numeric vector fall in specified range?

Description

This is a shortcut for x >= left & x <= right.

Usage

between(x, left, right)

Arguments

x

A numeric vector of values.

left, right

Boundary values.

Value

A logical vector the same length as x.

Examples

between(1:12, 7, 9)

x <- rnorm(1e2)
x[between(x, -1, 1)]


[Package poorman version 0.2.7 Index]