stringi (version 0.2-3)

stri_prepare_arg_logical: Prepare a Logical Vector Argument [internal]

Description

This is an internal function. However, the interested user may play with it in order to get more insight on how stringi deals with its functions' arguments. See `Value' section for details.

Usage

stri_prepare_arg_logical(x)

Arguments

x
argument to be checked

Value

  • If x is a logical vector, it is returned with no change. If x is a factor, as.character is called, and the resulting character vector is coerced to logical. If atomic vector or a matrix is given, it is coerced to a logical vector. Otherwise the function throws an error.

See Also

Other prepare_arg: stri_prepare_arg_double_1; stri_prepare_arg_double; stri_prepare_arg_integer_1; stri_prepare_arg_integer; stri_prepare_arg_logical_1; stri_prepare_arg_raw; stri_prepare_arg_string_1; stri_prepare_arg_string; stringi-arguments