R/hides_mat.R

#' @rdname hides
#' @export
hides_mat <- function(x, ...){
  UseMethod("hides_mat")
}

hides_mat.environment <- function(x, ...){
  hides_mat.list(x, ...)
}

hides_mat.list <- function(x, ...){
hides_df(x, ...) &&
  length(unique(sapply(x,typeof))) == 1
}

hides_mat.data.frame <- function(x, ...){
  length(unique(sapply(x,typeof)))
}

hides_mat.default <- function(x, ...){
  FALSE
}
moodymudskipper/hidden documentation built on May 20, 2019, 9:59 a.m.