R/set_equal_y_limits.R

Defines functions set_equal_y_limits

set_equal_y_limits <- function(x) {
  stopifnot(is.list(x))
  classes <- sapply(x, class)
  if(!all(apply(classes,1,function(X) length(unique(X))==1))) {
    stop("All members of the list must have the same class")
  }
  class(x) <- classes[1]
  UseMethod("set_equal_y_limits", x)
}
ericdunipace/limbs documentation built on June 11, 2025, 9:50 a.m.