<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to winsorize in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214978#M52929</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you again Reeza, My first time using these macros.&amp;nbsp; It works. Would you know by a chance how to modify the macro so the winsorized variables have different names than the original varialbes?&amp;nbsp; For instance, creating&amp;nbsp; new names for the winsorized variables adding _winsor to the original name?&amp;nbsp; I tried several things but I was not successful Thank you again&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 26 Jun 2015 20:53:29 GMT</pubDate>
    <dc:creator>Thomas_mp</dc:creator>
    <dc:date>2015-06-26T20:53:29Z</dc:date>
    <item>
      <title>How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214976#M52927</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello, I have several (hundreds of) variables that I need to “winsorize” at some level, let us say at the 95% and 5%.&amp;nbsp; As you know, this&amp;nbsp; means that all the observations with values &amp;gt; 95 percentile take the value of the 95% percentile , and all observations with value less than the 5% percentile take the value of the 5th percentile. I have been using the proc univariate, get the p5 and p95, and use “if” statements : For instance for a variable Raw1, I compute the 95 and 5 percentiles, I create a new variable Raw1_w&amp;nbsp; and I "winsorize" it with if statements. Raw1_w =&amp;nbsp; Raw1; if&amp;nbsp; Raw1 &amp;lt; Raw1_p5&amp;nbsp; then Raw1_w =&amp;nbsp; Raw1_p5; if&amp;nbsp; Raw1 &amp;gt; Raw1_p95&amp;nbsp; then Raw1_w =&amp;nbsp; Raw1_p95; if&amp;nbsp; Raw1 =.&amp;nbsp; then Raw1_w = .; The problem is that when I have several hundreds variables, this 4 lines of code per variable result in a&amp;nbsp; very complex and very long program and I make mistakes too frequently .. , and I was wondering if you can think in a better solution to do this. Thank you&amp;nbsp; !!!,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Jun 2015 17:45:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214976#M52927</guid>
      <dc:creator>Thomas_mp</dc:creator>
      <dc:date>2015-06-26T17:45:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214977#M52928</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use a macro.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's one that caps outliers using 25/75 but could easily be modified for 5/95 and caps them. &lt;/P&gt;&lt;P&gt;&lt;A href="https://gist.github.com/statgeek/31316a678433a1db8136" title="https://gist.github.com/statgeek/31316a678433a1db8136"&gt;SAS Box-Plot/Tukey Method of Capping Outliers&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If it's to calculate means/statistics proc univariate will also do that using winsorize option. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Jun 2015 17:49:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214977#M52928</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-06-26T17:49:30Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214978#M52929</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you again Reeza, My first time using these macros.&amp;nbsp; It works. Would you know by a chance how to modify the macro so the winsorized variables have different names than the original varialbes?&amp;nbsp; For instance, creating&amp;nbsp; new names for the winsorized variables adding _winsor to the original name?&amp;nbsp; I tried several things but I was not successful Thank you again&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Jun 2015 20:53:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214978#M52929</guid>
      <dc:creator>Thomas_mp</dc:creator>
      <dc:date>2015-06-26T20:53:29Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214979#M52930</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Modify the macro slightly - I'm adding the win to the beginning of the variable because that will allow you to use naming shortcuts in SAS later on if required. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P class="line" id="file-sas_bp_cap_outliers-LC16"&gt;%macro cap(dset=,var=, lower=, upper=);&lt;/P&gt;&lt;P class="line" id="file-sas_bp_cap_outliers-LC17"&gt;&lt;/P&gt;&lt;P class="line" id="file-sas_bp_cap_outliers-LC18"&gt;data &amp;amp;dset;&lt;/P&gt;&lt;P class="line" id="file-sas_bp_cap_outliers-LC19"&gt;set &amp;amp;dset;&lt;/P&gt;&lt;P class="line"&gt;win_&amp;amp;var = &amp;amp;var;&lt;/P&gt;&lt;P class="line" id="file-sas_bp_cap_outliers-LC20"&gt;if &amp;amp;var&amp;gt;&amp;amp;upper then &lt;SPAN style="font-size: 13.3333330154419px;"&gt;win_&amp;amp;var&lt;/SPAN&gt;=&amp;amp;upper;&lt;/P&gt;&lt;P class="line" id="file-sas_bp_cap_outliers-LC21"&gt;if &amp;amp;var&amp;lt;&amp;amp;lower then &lt;SPAN style="font-size: 13.3333330154419px;"&gt;win_&amp;amp;var&lt;/SPAN&gt;=&amp;amp;lower;&lt;/P&gt;&lt;P class="line" id="file-sas_bp_cap_outliers-LC22"&gt;run;&lt;/P&gt;&lt;P class="line" id="file-sas_bp_cap_outliers-LC23"&gt;&lt;/P&gt;&lt;P class="line" id="file-sas_bp_cap_outliers-LC24"&gt;%mend;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Jun 2015 20:58:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214979#M52930</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-06-26T20:58:41Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214980#M52931</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you again !!!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Jun 2015 22:14:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214980#M52931</guid>
      <dc:creator>Thomas_mp</dc:creator>
      <dc:date>2015-06-26T22:14:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214981#M52932</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here is a simple IML code .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;H3 style="color: #353535; font-family: Lato, sans-serif; background-color: #f0f1f2;"&gt;Code: Program&lt;/H3&gt;&lt;PRE class="sce-render" style="font-family: 'Courier New', Menlo, 'Lucida Console'; font-size: 16px;"&gt;&lt;SPAN class="sec-keyword" style="color: #000080; font-weight: bold;"&gt;data&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;have&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;do&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;1&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;to&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;100&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="text" style="color: black;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;a&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;ceil&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;ranuni&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;1&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;)&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;*&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;100&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;)&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="text" style="color: black;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;b&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;ceil&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;ranuni&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;2&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;)&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;*&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;100&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;)&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="text" style="color: black;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;output&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;end&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;drop&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="sec-keyword" style="color: #000080; font-weight: bold;"&gt;run&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN class="macro-keyword" style="color: #0000ff;"&gt;%let&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;low&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;0.05&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="macro-keyword" style="color: #0000ff;"&gt;%let&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;high&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;0.95&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN class="sec-keyword" style="color: #000080; font-weight: bold;"&gt;proc&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="sec-keyword" style="color: #000080; font-weight: bold;"&gt;iml&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;use&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;have&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;read&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;all&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;var&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;_num_&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;into&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;x&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;c&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;vname&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;close&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;have&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;call&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;qntl&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;q&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;x&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;{&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;&amp;amp;&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;low&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;&amp;amp;&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;high&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;}&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;)&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;do&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;1&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;to&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;ncol&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;x&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;)&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;x&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;loc&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;x&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;q&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;1&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;)&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;q&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;1&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;x&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;loc&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;x&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;q&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;2&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;)&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;q&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="numeric" style="color: #008080; font-weight: bold;"&gt;2&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;,&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;i&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;end&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;create&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;want&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;from&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;x&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;[&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;c&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;vname&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;]&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;append&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;from&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;x&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN class="keyword" style="color: #0000ff;"&gt;close&lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt; &lt;/SPAN&gt;&lt;SPAN class="text" style="color: black;"&gt;want&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN class="sec-keyword" style="color: #000080; font-weight: bold;"&gt;quit&lt;/SPAN&gt;&lt;SPAN class="sep" style="color: black;"&gt;;&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Xia Keshan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 27 Jun 2015 07:12:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214981#M52932</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2015-06-27T07:12:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214982#M52933</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The previous solutions have two problems:&lt;/P&gt;&lt;P&gt;1) They do not correctly Winsorize the data&lt;/P&gt;&lt;P&gt;2) They do not handle missing values&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Winsorization does not involve quantiles. To Winsorize, you specify an integer k. You then replace the lowest (nonmissing) k values by the (k+1)st ordered value, and replace the highest k values by the (n-k)th ordered value, where n is the number of nonmissing observations. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Notice that if there are repeated values in the tails, then Winsorizing is different than "capping" and&amp;nbsp; quantiles are not the same as choosing k. For example, if k=2 and the data are&lt;/P&gt;&lt;P&gt;0 4 4 4 5 5 6 6 6 20&lt;/P&gt;&lt;P&gt;then the Winsorized data should be&lt;/P&gt;&lt;P&gt;4 4 4 4 5 5 6 6 6 6&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is a SAS/IML program that Winsorizes data. To validate, take the (ordinary) mean of the Winsorized data and compare to the Winsorized means as computed by using PROC UNIVARIATE:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;%let dsname = sashelp.heart;&lt;/P&gt;&lt;P&gt;/* SAS/IML program to Winsorize data */&lt;BR /&gt;/* Modified from the "trimmed mean" algorithm in &lt;BR /&gt;&amp;nbsp;&amp;nbsp; Wicklin (2010) "Rediscovering SAS/IML Software", p 2-3 */&lt;BR /&gt;proc iml;&lt;/P&gt;&lt;P&gt;start Winsorize(x, prop);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; p = ncol(x);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* number of columns */&lt;BR /&gt;&amp;nbsp;&amp;nbsp; w = x;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* copy of x */&lt;BR /&gt;&amp;nbsp;&amp;nbsp; do i = 1 to p;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; z = x[,i];&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* copy i_th column */&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; n = countn(z);&amp;nbsp;&amp;nbsp;&amp;nbsp; /* count nonmissing values */&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; k = ceil(prop*n); /* number of observations to trim */&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; r = rank(z);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* rank data in i_th column */&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* find target values and obs with smaller/larger values */&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; lowIdx = loc(r&amp;lt;=k &amp;amp; r^=.);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; lowVal = z[loc(r=k+1)]; &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; highIdx = loc(r&amp;gt;=n-k+1);&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; highVal = z[loc(r=n-k)]; &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; /* Winsorize k largest and k smallest values */&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; w[lowIdx,i] = lowVal;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; w[highIdx,i] = highVal;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; end;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; return(w);&lt;BR /&gt;finish;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/* test it */&lt;/P&gt;&lt;P&gt;use &amp;amp;dsname;&lt;BR /&gt;read all var _NUM_ into X[colname=varNames];&lt;BR /&gt;close;&lt;BR /&gt;winX = Winsorize(X, 0.1);&lt;/P&gt;&lt;P&gt;/* Optional: compute Winsorized mean = mean of the Winsorized data */&lt;BR /&gt;winMean = mean(winX);&lt;BR /&gt;print winMean[c=varNames f=8.4];&lt;/P&gt;&lt;P&gt;/* write Winsorized data to data set, if necessary */ &lt;BR /&gt;quit;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;/* Validation: compute Winsorized means by using UNIVARIATE */&lt;BR /&gt;ods graphics off;&lt;BR /&gt;ods exclude all;&lt;BR /&gt;proc univariate data=&amp;amp;dsname winsorized=0.1;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; ods output WinsorizedMeans=winMeans;&lt;BR /&gt;run;&lt;BR /&gt;ods exclude none;&lt;BR /&gt;proc print data=winMeans;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; var VarName HalfP HalfN Mean;&lt;BR /&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Jun 2015 14:51:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214982#M52933</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2015-06-29T14:51:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214983#M52934</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Rick, that is good to know.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Jun 2015 15:12:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214983#M52934</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-06-29T15:12:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214984#M52935</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Rick,&lt;/P&gt;&lt;P&gt;I see the problems .&amp;nbsp; One question is that you mention you need to specify an integer K.&amp;nbsp; Perhaps a problem is that this integer should be (for instance) the 20 percentile, and 80 percentile (to winsorize at the 20 % and 80%), so k is different for each variable. See for instance the desired output. The first column&amp;nbsp; is an ID, columns 2 and 3 have the data for Va and VB,&amp;nbsp; the other 2 columns have two variables winsorized.&amp;nbsp; Va has several missing values.&lt;/P&gt;&lt;P&gt;My question is thus, how can this program be “adapted” to make “k” be the percentile desired to winsorize at the 20%-80%instead of a fix number?&lt;/P&gt;&lt;P&gt;Thank you again,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;id Va Vb&amp;nbsp;&amp;nbsp; Va_win Vb_win&lt;/P&gt;&lt;P&gt;2 4 1001&amp;nbsp;&amp;nbsp; 4 998&lt;/P&gt;&lt;P&gt;3 . 1000&amp;nbsp;&amp;nbsp; . 998&lt;/P&gt;&lt;P&gt;4 4 999&amp;nbsp;&amp;nbsp; 4 998&lt;/P&gt;&lt;P&gt;5 . 998&amp;nbsp;&amp;nbsp; . 998&lt;/P&gt;&lt;P&gt;6 5 997&amp;nbsp;&amp;nbsp; 5 997&lt;/P&gt;&lt;P&gt;7 6 996&amp;nbsp;&amp;nbsp; 6 996&lt;/P&gt;&lt;P&gt;8 . 995&amp;nbsp;&amp;nbsp; . 995&lt;/P&gt;&lt;P&gt;9 8 994&amp;nbsp;&amp;nbsp; 8 994&lt;/P&gt;&lt;P&gt;10 9 993&amp;nbsp;&amp;nbsp; 9 993&lt;/P&gt;&lt;P&gt;18 . 985&amp;nbsp;&amp;nbsp; . 985&lt;/P&gt;&lt;P&gt;19 18 984&amp;nbsp;&amp;nbsp; 18 984&lt;/P&gt;&lt;P&gt;20 . 983&amp;nbsp;&amp;nbsp; . 983&lt;/P&gt;&lt;P&gt;21 20 982&amp;nbsp;&amp;nbsp; 20 982&lt;/P&gt;&lt;P&gt;22 . 981&amp;nbsp;&amp;nbsp; . 981&lt;/P&gt;&lt;P&gt;23 . 980&amp;nbsp;&amp;nbsp; . 980&lt;/P&gt;&lt;P&gt;24 . 979&amp;nbsp;&amp;nbsp; . 979&lt;/P&gt;&lt;P&gt;25 . 978&amp;nbsp;&amp;nbsp; . 978&lt;/P&gt;&lt;P&gt;26 25 977&amp;nbsp;&amp;nbsp; 25 978&lt;/P&gt;&lt;P&gt;27 . 976&amp;nbsp;&amp;nbsp; . 978&lt;/P&gt;&lt;P&gt;28 26 976&amp;nbsp;&amp;nbsp; 25 978&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Jun 2015 16:24:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214984#M52935</guid>
      <dc:creator>Thomas_mp</dc:creator>
      <dc:date>2015-06-29T16:24:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214985#M52936</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you want to just cap it at the values of the 20th and 80th percentiles, see the answers by the others. In particular, @Ksharp has already shown how to use the QNTL function in IML to replace values less than (resp., greater than) the 20th (resp, 80th)&amp;nbsp; percentile.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Just understand that what you are doing is slightly different than the Winsorization method that PROC UNIVARIATE uses.&amp;nbsp; If there are no repeated values and no missing values, the two methods are equivalent, I think. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Jun 2015 17:30:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214985#M52936</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2015-06-29T17:30:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214986#M52937</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I don't see the difference in what I've coded &lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;and how Wikipedia and NumPy define Winsorize :smileyconfused:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://en.wikipedia.org/wiki/Winsorising" style="font-size: 10pt; line-height: 1.5em;" title="https://en.wikipedia.org/wiki/Winsorising"&gt;Winsorising - Wikipedia, the free encyclopedia&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://docs.scipy.org/doc/scipy-0.14.0/reference/generated/scipy.stats.mstats.winsorize.html" title="http://docs.scipy.org/doc/scipy-0.14.0/reference/generated/scipy.stats.mstats.winsorize.html"&gt;scipy.stats.mstats.winsorize &amp;amp;mdash; SciPy v0.14.0 Reference Guide&lt;/A&gt; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Jun 2015 17:37:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214986#M52937</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2015-06-29T17:37:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214987#M52938</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes, the Wikipedia article uses a different definition than PROC UNIVARIATE does. The UNIVARIATE procedure uses the statistical definition of the symmetric Winsorization as studied by Tukey and colleagues in s series of papers.&amp;nbsp; (Symmetric means change k values in the upper and lower tails.) By using the Tukey definition, you can get &lt;A href="http://support.sas.com/documentation/cdl/en/procstat/67528/HTML/default/viewer.htm#procstat_univariate_details22.htm"&gt;standard errors, confidence intervals, and other distributional information &lt;/A&gt;about the Winsorized mean.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There's nothing inherently wrong with replacing via quantiles, but I don't know whether the distribution of the resulting statistics is understood for that nonsymmetric case.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 29 Jun 2015 17:57:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214987#M52938</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2015-06-29T17:57:14Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214988#M52939</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;@Rick&lt;/P&gt;&lt;P&gt;There are two different way to define winsorize in &lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; background-color: #ffffff;"&gt; PROC UNIVARIATE &lt;/SPAN&gt;, one is like yours , another is as OP's said.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Xia Keshan&amp;nbsp; (a.k.a&amp;nbsp; Ksharp)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 30 Jun 2015 12:06:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214988#M52939</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2015-06-30T12:06:21Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214989#M52940</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No, UNIVARIATE uses only the symmetric definition.&amp;nbsp; however, you can specify the number of observations to Winsorize as an integer, k, or as a percentage (0.1=10%).&amp;nbsp;&amp;nbsp; In both cases the procedure Winsorizes the same number of observations in both tails.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Percentages are not the same as percentiles. As I show in my response, when there are repeated values this is not the same as changing all data less than the alpha_th percentile and all data greater than the (1-alpha)th percentile. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jul 2015 19:58:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/214989#M52940</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2015-07-06T19:58:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to winsorize</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/278174#M58838</link>
      <description>&lt;P&gt;In case this thread is referenced in the future, I am including a link to the article &lt;A href="http://blogs.sas.com/content/iml/2015/07/15/winsorize-data.html" target="_self"&gt;"How to Winsorize data in SAS,"&lt;/A&gt; in which I consolidate my thoughts on this issue.&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jun 2016 12:43:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-winsorize/m-p/278174#M58838</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2016-06-17T12:43:52Z</dc:date>
    </item>
  </channel>
</rss>

