R/imports-other.R

Defines functions dropInf

# This function has been imported from stats.plot.lm()
dropInf <- function(x, h) {
  if (any(isInf <- h >= 1)) {
    warning(
      gettextf(
        "Not plotting observations with leverage one:\n  %s",
        paste(which(isInf), collapse = ", ")
      ),
      call. = FALSE,
      domain = NA
    )
    x[isInf] <- NaN
  }
  x
}

Try the tactile package in your browser

Any scripts or data that you put into this service are public.

tactile documentation built on Aug. 8, 2025, 7:44 p.m.