Learn R Programming

PairedData (version 0.5)

winval: Data winsorization

Description

Compute the Winsorized values for data x. tr is the amount of Winsorization which defaults to .2. (from Wilcox, 2005)

Usage

winval(x,tr=.2)

Arguments

x
Sample data
tr
Percentage of trimming

Value

  • The winsorized values

References

Wilcox, R.R. (2005). Introduction to robust estimation and hypothesis testing. Academic Press.

Examples

Run this code
x<-rnorm(20)
sort(x)
winval(x)

Run the code above in your browser using DataLab