outlier_plot: Make boxplots of numberic variable

Description Usage Arguments See Also Examples

View source: R/outliers.R

Description

This function can optionally show outliers identifying by df$is_outliers if show_outliers = TRUE.

Usage

1
2
3
4
5
6
7
8
outlier_plot(
  df,
  var,
  grp,
  apply_log = FALSE,
  show_outliers = FALSE,
  ignore_zero = FALSE
)

Arguments

df

data frame with outliers identified with df$is_outlier

var

Unquoted name of variable to check

grp

Unquoted name of variable to group by

apply_log

If TRUE, log transform input values prior to applying tukey's rule. Useful since distributions often have a log-normal shape (e.g., spending)

show_outliers

If TRUE, will identify which values have been flagged with df$is_outlier

ignore_zero

If TRUE, will exclude zero values from IQR & flagging. Note that zeroes will automatically be ignored if apply_log = TRUE

See Also

Other functions for identifying outliers: outlier_mean_compare(), outlier_pct(), outlier_tukey()

Examples

1
# see ?outlier_tukey

southwick-associates/sastats documentation built on March 27, 2020, 9:39 p.m.