winsorization: winsorization

Description Usage Arguments Value Examples

Description

Its purposes is to eliminate outliers in a following way. Values lower or higher than a certain percentile will be replaced by the percentile. The function is taken from package DescTools.

Usage

1
winsorization(x, perc_d, perc_u)

Arguments

x

a input vector

perc_d

lower percentile, which will be used for winsoriation

perc_u

lower percentile, which will be used for winsoriation

Value

Winsorized vector x

Examples

1
2
example_vector=c(-1000,1,2,3,4,5,6,7,8,9,1000)
winsorization(example_vector,0.05,0.95)

pmaletic/KYuC documentation built on June 22, 2019, 6:34 p.m.