Description Usage Arguments Value Author(s) References Examples

View source: R/auxiliary_functions.R

Function performs Winsor normalization of a supplied vector. Steps: 1. Calcualate top winsor value [(1+winsor_level)/2 quantile], and bottom winsor value ((1-winsor_level)/2 quantile) 2. Each value below bottom winsor value set to bottom winsor value; each value above top winsor value set to top winsor value 3. Transform linearly all the values to [0,1] range

1 |

`input_vector` |
Vector with values to be Winsorized |

`winsor_level` |
Winsorization level. Bottom outliers will be set to (1-winsor_level)/2 quantile and top outliers to (1+winsor_level)/2 quantile. |

`only_top` |
If TRUE then bottom values are not Winsorized and the lowest is set to 0. |

Vector of numerics within <0,1>.

Lukasz Jan Kielpinski

Hastings, Cecil; Mosteller, Frederick; Tukey, John W.; Winsor, Charles P. Low Moments for Small Samples: A Comparative Study of Order Statistics. The Annals of Mathematical Statistics 18 (1947), no. 3, 413–426.

1 2 |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.