routlier: Remove or flag outliers in a data frame

Description Usage Arguments

Description

Remove or flag outliers in a data frame

Usage

1
2
routlier(.data, ..., action = c("na", "flag", "remove"), z = c(-3, 3),
  absolute = NULL, info = FALSE)

Arguments

.data

a data frame

...

names of the columns to check for outliers

action

character string indicating how to deal with outliers, can be one of "na" (outliers are turned into NA; default), "remove" (rows containing outliers are removed from the data frame) or "flag" (a new logical variable "outlier" is added to the data frame indicating which rows contain outliers).

z

numeric vector of length two indicating the lower and upper z-score limits for outlier detection. If only one side should be scanned use e.g. c(NA, 3).

absolute

numeric vector of length two indicating the absolute lower and upper limits for outlier detection. If only one side should be scanned use e.g. c(10, NA).

info

logical indicating whether to print the number of outliers detected to the console.


dgromer/psymisc documentation built on May 15, 2019, 7:22 a.m.