metan (version 1.2.1)

find_outliers: Find possible outliers in a dataset

Description

Find possible outliers in the dataset.

Usage

find_outliers(
  .data = NULL,
  var = NULL,
  by = NULL,
  values = NULL,
  plots = FALSE,
  coef = 1.5,
  verbose = TRUE,
  plot_theme = theme_metan()
)

Arguments

.data

The data to be analyzed. Must be a dataframe or an object of class split_factors.

var

The variable to be analyzed.

by

One variable (factor) to split the data into subsets. The function is then applied to each subset and returns a list where each element contains the results for one level of the variable in by. To split the data by more than one factor variable, use the function split_factors to pass subsetted data to .data.

values

An alternative way to pass the data to the function. It must be a numeric vector.

plots

If TRUE, then histograms and boxplots are shown.

coef

The multiplication coefficient, defaults to 1.5. For more details see ?boxplot.stat.

verbose

If verbose = TRUE then some results are shown in the console.

plot_theme

The graphical theme of the plot. Default is plot_theme = theme_metan(). For more details, see theme.

Examples

Run this code
# NOT RUN {
library(metan)

find_outliers(data_ge2, var = PH, plots = TRUE)

# Find outliers within each environment
find_outliers(data_ge2, var = PH, by = ENV)
# }
# NOT RUN {
# }

Run the code above in your browser using DataLab