winsorize function

Winsorize Data

Winsorize Data

This function Winsorizes a fraction gamma of a numeric data set.

winsorize(x, fraction = 0.1)

Arguments

  • x: A numeric data set
  • fraction: A fraction greater than 0 and less than 0.5

Returns

The Winsorized numeric data

Details

The Winsorized data is obtained by by setting the gamma smallest data values equal to the next smallest value, and setting the gamma largest data values equal to the next largest data value.

Examples

x <- rt(10,8) winsorize(x,0.2)
  • Maintainer: Doug Martin
  • License: GPL-2
  • Last published: 2023-08-30

Useful links