check-scalar-isOfDimension: Does the input contain specific dimensions?

check-scalar-isOfDimensionR Documentation

Does the input contain specific dimensions?

Description

Does the input contain specific dimensions?

Usage

isOfDimension(x, n)

Arguments

x

Object.

n

integer(1). Number to include.

Value

TRUE on success; FALSE on failure, with cause set.

Note

Updated 2021-10-08.

See Also

  • assertive.properties::is_of_dimension().

Examples

x <- data.frame(a = c(TRUE, FALSE), b = c(FALSE, TRUE))
dim(x)

## TRUE ====
isOfDimension(x, n = c(2L, 2L))

## FALSE ====
isOfDimension(x, n = c(1L, 2L))
isOfDimension(x, n = c(2L, 1L))

acidgenomics/r-goalie documentation built on Jan. 12, 2024, 4:15 a.m.