replace_outliers: Replace outliers in the variable with one of summary...

Description Usage Arguments Value Examples

View source: R/replace_outliers.R

Description

Replace outliers in the variable with one of summary statistic for that variable or for a grouped by category summary statistic

Usage

1
2
replace_outliers(data, group_var, target_var, group,
  replacement_stat = "median")

Arguments

data

Data frame from which to calculate the replacement number.

group_var

Variable for grouping.

target_var

Variable in which outliers are to be replaced.

group

Group or category for which to calculate the replacement number.

replacement_stat

Which summary statistic to use. "Median" by default.

Value

Single number, summary statistic.

Examples

1
group_median <- replace_outliers(ad_metrics, 96)

nikdudaev/ndr documentation built on Nov. 19, 2019, 2:20 a.m.