R/is_matrix.R

Defines functions is_matrix

Documented in is_matrix

#' Assess whether an object is a Matrix
#'
#' Assess whether an object is a Matrix or one of
#'  its derived object types.
#'
#' @param X Object.
#' 
#' @return boolean
#' 
#' @importFrom methods is
is_matrix <- function(X) {
    methods::is(X, "Matrix") || methods::is(X, "matrix")
}
NathanSkene/EWCE documentation built on Nov. 3, 2024, 8:16 a.m.