Learn R Programming

visdat (version 0.5.3)

test_if_dataframe: Test if input is a data.frame

Description

Test if input is a data.frame

Usage

test_if_dataframe(x)

Value

an error if input (x) is not a data.frame

Arguments

x

object

Examples

Run this code
if (FALSE) {
# success
test_if_dataframe(airquality)
#fail
test_if_dataframe(AirPassengers)
}

Run the code above in your browser using DataLab