check_tabular: Check object is tabular

View source: R/check.R

check_tabularR Documentation

Check object is tabular

Description

Checks if object is of class data.frame, data.table, or tbl_df.

Usage

check_tabular(x)

Arguments

x

Object to check.

Value

Called for side effects. Throws an error if input is not tabular, returns x invisibly otherwise.

Author(s)

EDG

Examples

check_tabular(iris)
check_tabular(data.table::as.data.table(iris))
# Throws error:
try(check_tabular(matrix(1:10, ncol = 2)))

rtemis.core documentation built on April 22, 2026, 1:11 a.m.