<?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: ODS OUTPUT WilcoxonTest for PROC NPAR1WAY gives ambiguous result in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766782#M37489</link>
    <description>&lt;P&gt;&lt;A href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884" target="_self"&gt;ballardw&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Thank you for replying, but I have already tested the option with&amp;nbsp;BY statement.&lt;/P&gt;&lt;P&gt;Adding this setting does not affect the response dataset &lt;U&gt;&lt;STRONG&gt;format&lt;/STRONG&gt;&lt;/U&gt;.&lt;/P&gt;&lt;P&gt;For example, your first example gives the following result:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="изображение.png" style="width: 999px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/63419i905EFB2EC7C9666A/image-size/large?v=v2&amp;amp;px=999" role="button" title="изображение.png" alt="изображение.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;There are no variables named &lt;STRONG&gt;Name1, cValue1, nValue1... &lt;/STRONG&gt;which i need to my own macro.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;At the same time, the ODS output from PROC FREQ gives exactly what I want (but I want this for the PROC NPAR1WAY):&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods output FishersExact = ftestp;
proc freq data = sashelp.cars;
	tables  origin*drivetrain/exact;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="изображение.png" style="width: 999px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/63420i8EB2AF659BC175F9/image-size/large?v=v2&amp;amp;px=999" role="button" title="изображение.png" alt="изображение.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Thank you!&lt;/STRONG&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 09 Sep 2021 08:43:41 GMT</pubDate>
    <dc:creator>Kirill_Voronov</dc:creator>
    <dc:date>2021-09-09T08:43:41Z</dc:date>
    <item>
      <title>ODS OUTPUT WilcoxonTest for PROC NPAR1WAY gives ambiguous result</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766719#M37485</link>
      <description>&lt;P&gt;&lt;STRONG&gt;Hello SAS community!&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;While reading&lt;SPAN class="aCOpRe ljeAnf" style="-webkit-line-clamp: 2;"&gt;&lt;SPAN&gt;&lt;EM&gt;&amp;nbsp;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/SPAN&gt; &lt;A title="Paper 2442-2015" href="https://support.sas.com/resources/papers/proceedings15/2442-2015.pdf" target="_blank" rel="noopener"&gt;this paper&lt;/A&gt; (page 12), I came across an ambiguous output.&lt;/P&gt;&lt;P&gt;Judging by the code given in the paper (screenshot attached),&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="изображение.png" style="width: 999px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/63412i23DE195C25088FA3/image-size/large?v=v2&amp;amp;px=999" role="button" title="изображение.png" alt="изображение.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;the output dataset &lt;EM&gt;&lt;STRONG&gt;wtestp&lt;/STRONG&gt;&lt;/EM&gt; should contain the following variables:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;Name1&lt;/LI&gt;&lt;LI&gt;cValue1&lt;/LI&gt;&lt;LI&gt;nValue1&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;However, when trying to reproduce the output (at least in sas version 9.4), it turned out to be completely different (not in relation to the data presented, but in relation to the structure of the data set).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;A reproducible example:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods output WilcoxonTest = wtestp;
proc npar1way data = sashelp.class wilcoxon;
	class sex;
	var age;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;The &lt;EM&gt;&lt;STRONG&gt;wtestp&lt;/STRONG&gt;&lt;/EM&gt; output is not at all similar to that in paper. It doesn't contain any variables with such names, and none of the variables contains the values "P2_WALL" 2_WALL.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="изображение.png" style="width: 999px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/63411i2409F029D4359BDB/image-size/large?v=v2&amp;amp;px=999" role="button" title="изображение.png" alt="изображение.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;It is clear that the p-values are eventually obtained. But, this output doesn't allow them to be used in the macro as it was originally intended.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is it possible that I am doing something wrong and there is an opportunity to get the desired result?&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;Thank in advance for any help&lt;/EM&gt;!&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 08 Sep 2021 22:31:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766719#M37485</guid>
      <dc:creator>Kirill_Voronov</dc:creator>
      <dc:date>2021-09-08T22:31:25Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT WilcoxonTest for PROC NPAR1WAY gives ambiguous result</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766740#M37486</link>
      <description>&lt;P&gt;Do not expect the same sorts of output when you remove BY variables from code.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This, which&amp;nbsp; uses a BY statement does have those variables.&lt;/P&gt;
&lt;PRE&gt;proc sort data=sashelp.class
    out=work.class;
    by age;
run;
ods output WilcoxonTest = wtestp;
proc npar1way data = work.class wilcoxon;
   by age;
   class sex;
   var height;
run;&lt;/PRE&gt;
&lt;P&gt;If you want to use code from someone else's macros your call and data have to match, in this case include a BY statement. Even a trivial variable:&lt;/P&gt;
&lt;PRE&gt;data work.classjunk;
   set sashelp.class;
   bybob='1';
run;
ods output WilcoxonTest = wtestp;
proc npar1way data = work.classjunk wilcoxon;
   by bybob;
	class sex;
	var height;
run;&lt;/PRE&gt;
&lt;P&gt;The target of that paper is to use BY group processing as way to avoid making multiple single procedure calls to get the output for multiple calls. So when you bypass the multiple calls, i.e. BY group processing, then the data is not in the expected form to use the reporting parts because it would not be needed.&lt;/P&gt;</description>
      <pubDate>Thu, 09 Sep 2021 01:11:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766740#M37486</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2021-09-09T01:11:52Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT WilcoxonTest for PROC NPAR1WAY gives ambiguous result</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766782#M37489</link>
      <description>&lt;P&gt;&lt;A href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13884" target="_self"&gt;ballardw&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Thank you for replying, but I have already tested the option with&amp;nbsp;BY statement.&lt;/P&gt;&lt;P&gt;Adding this setting does not affect the response dataset &lt;U&gt;&lt;STRONG&gt;format&lt;/STRONG&gt;&lt;/U&gt;.&lt;/P&gt;&lt;P&gt;For example, your first example gives the following result:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="изображение.png" style="width: 999px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/63419i905EFB2EC7C9666A/image-size/large?v=v2&amp;amp;px=999" role="button" title="изображение.png" alt="изображение.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;There are no variables named &lt;STRONG&gt;Name1, cValue1, nValue1... &lt;/STRONG&gt;which i need to my own macro.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;At the same time, the ODS output from PROC FREQ gives exactly what I want (but I want this for the PROC NPAR1WAY):&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods output FishersExact = ftestp;
proc freq data = sashelp.cars;
	tables  origin*drivetrain/exact;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="изображение.png" style="width: 999px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/63420i8EB2AF659BC175F9/image-size/large?v=v2&amp;amp;px=999" role="button" title="изображение.png" alt="изображение.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Thank you!&lt;/STRONG&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Sep 2021 08:43:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766782#M37489</guid>
      <dc:creator>Kirill_Voronov</dc:creator>
      <dc:date>2021-09-09T08:43:41Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT WilcoxonTest for PROC NPAR1WAY gives ambiguous result</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766802#M37491</link>
      <description>&lt;P&gt;&lt;A href="https://documentation.sas.com/doc/en/pgmsascdc/9.4_3.4/statug/statug_whatsnew_sect036.htm" target="_self"&gt;According to the documentation&lt;/A&gt;, PROC NPAR1WAY changed the format of score test tables in SAS/STAT 15.1 (SAS 9.4M6). The doc says "You can specify the TABLES=RESTORE option in the PROC NPAR1WAY statement to display these tables in factoid (label-value) format, which is their format in releases before SAS/STAT 15.1."&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For your reproducible example:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods output WilcoxonTest = wtestp;
proc npar1way data = sashelp.class wilcoxon tables=restore;
	class sex;
	var age;
run;

proc print data=wtestp; run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 09 Sep 2021 10:06:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766802#M37491</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2021-09-09T10:06:33Z</dc:date>
    </item>
    <item>
      <title>Re: ODS OUTPUT WilcoxonTest for PROC NPAR1WAY gives ambiguous result</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766807#M37492</link>
      <description>Thank you very much. It helped a lot!</description>
      <pubDate>Thu, 09 Sep 2021 10:26:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/ODS-OUTPUT-WilcoxonTest-for-PROC-NPAR1WAY-gives-ambiguous-result/m-p/766807#M37492</guid>
      <dc:creator>Kirill_Voronov</dc:creator>
      <dc:date>2021-09-09T10:26:53Z</dc:date>
    </item>
  </channel>
</rss>

