Learn R Programming

tidytidbits (version 0.3.2)

truthy: A python / javascript-like "truthy" notion

Description

Values are truthy that are not null, NA, empty, 0, or FALSE.

Usage

truthy(x)

falsy(x)

Arguments

x

Any object, value or NULL

Value

logical

Functions

  • falsy: x is not truthy

Details

Note that this is per se not vectorised, because a non-empty list or vector is "truthy" as such.