Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

is.what

Run Multiple is.* Tests on a Given Object


Description

Run multiple is.* tests on a given object: is.na, is.numeric, and many others.

Usage

is.what(object, verbose=FALSE)

Arguments

object

any R object.

verbose

whether negative tests should be included in output.

Value

A character vector containing positive tests, or when verbose is TRUE, a data frame showing all test results.

Note

The following procedure is used to look for valid tests:

  1. Find all objects named is.* in all loaded environments.

  2. Discard objects that are not functions.

  3. Include test result only if it is of class "logical", not an NA, and of length 1.

Author(s)

Arni Magnusson, inspired by demo(is.things).

See Also

is.na and is.numeric are commonly used tests.

Examples

is.what(pi)
is.what(NA, verbose=TRUE)
is.what(lm(1~1))
is.what(is.what)

gdata

Various R Programming Tools for Data Manipulation

v2.18.0
GPL-2
Authors
Gregory R. Warnes, Ben Bolker, Gregor Gorjanc, Gabor Grothendieck, Ales Korosec, Thomas Lumley, Don MacQueen, Arni Magnusson, Jim Rogers, and others
Initial release
2017-06-05

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.