logical3 {hutilscpp}R Documentation

Vectorized logical with support for short-circuits

Description

Vectorized logical with support for short-circuits

Usage

and3(x, y, z = NULL, nas_absent = FALSE)

or3(x, y, z = NULL)

Arguments

x, y, z

Logical vectors. If z is NULL the function is equivalent to the binary versions; only x and y are used.

nas_absent

(logical, default: FALSE) Can it be assumed that x,y,z have no missing values? Set to TRUE when you are sure that that is the case; setting to TRUE falsely has no defined behaviour.

Value

For and3, the same as x & y & z; for or3, the same as x | y | z, designed to be efficient when component-wise short-circuiting is available.


[Package hutilscpp version 0.10.5 Index]