"logical"
, and the basic
logical constants.
TRUE
FALSE
T; F
logical(length = 0)
as.logical(x, ...)
is.logical(x)
TRUE
and FALSE
are reserved words denoting logical
constants in the R language, whereas T
and F
are global
variables whose initial values set to these. All four are
logical(1)
vectors. Logical vectors are coerced to integer vectors in contexts where a
numerical value is required, with TRUE
being mapped to
1L
, FALSE
to 0L
and NA
to NA_integer_
.
NA
, the other logical constant.