<?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: add p values to output dataset of proc corr in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430132#M68591</link>
    <description>&lt;P&gt;What version of SAS are you using?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You add that single line of code into your proc corr procedure, exactly as is. Then a data set is created called WANT, check your log.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this doesn't work, please post your log and the exact code submitted.&lt;/P&gt;</description>
    <pubDate>Tue, 23 Jan 2018 19:43:29 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2018-01-23T19:43:29Z</dc:date>
    <item>
      <title>add p values to output dataset of proc corr</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430081#M68583</link>
      <description>&lt;P&gt;I am using this code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sort data= SomeData;
	by SomeGroup;
run;

proc corr data=SomeData nosimple pearson spearman outp=Temp;
	var x y;
	by SomeGroup;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Is there a way to get the p values into the output dataset Temp as well? I get correlations for values, which are definitely not correlated. So maybe a p value threshold could help ...&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jan 2018 17:02:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430081#M68583</guid>
      <dc:creator>csetzkorn</dc:creator>
      <dc:date>2018-01-23T17:02:14Z</dc:date>
    </item>
    <item>
      <title>Re: add p values to output dataset of proc corr</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430083#M68584</link>
      <description>&lt;P&gt;Aren’t P-Values in the output?&lt;/P&gt;
&lt;P&gt;If so, use the ODS table instead,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ods output pearsonCorr=want;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jan 2018 17:11:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430083#M68584</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-01-23T17:11:43Z</dc:date>
    </item>
    <item>
      <title>Re: add p values to output dataset of proc corr</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430117#M68589</link>
      <description>&lt;P&gt;As Reeza says, use &lt;A href="https://blogs.sas.com/content/iml/2017/01/09/ods-output-any-statistic.html" target="_self"&gt;ODS OUTPUT to save any statistic&lt;/A&gt;.&amp;nbsp; See &lt;A href="http://support.sas.com/kb/22/848.html" target="_self"&gt;http://support.sas.com/kb/22/848.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Since you have BY groups, &lt;A href="https://blogs.sas.com/content/iml/2015/05/26/suppress-ods.html" target="_self"&gt;use ODS EXCLUDE to suppress the output&lt;/A&gt; to the screen:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods exclude all;
proc corr data=SomeData;
ods output PearsonCorr=P;
	var x y;
	by SomeGroup;
run;
ods exclude none;

proc print data=P; run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jan 2018 19:43:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430117#M68589</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2018-01-23T19:43:44Z</dc:date>
    </item>
    <item>
      <title>Re: add p values to output dataset of proc corr</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430131#M68590</link>
      <description>Thanks please adopt my original code as I do not understand. I also have the suspicion the my sas version does not produce p values.</description>
      <pubDate>Tue, 23 Jan 2018 19:41:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430131#M68590</guid>
      <dc:creator>csetzkorn</dc:creator>
      <dc:date>2018-01-23T19:41:35Z</dc:date>
    </item>
    <item>
      <title>Re: add p values to output dataset of proc corr</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430132#M68591</link>
      <description>&lt;P&gt;What version of SAS are you using?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You add that single line of code into your proc corr procedure, exactly as is. Then a data set is created called WANT, check your log.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this doesn't work, please post your log and the exact code submitted.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jan 2018 19:43:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/add-p-values-to-output-dataset-of-proc-corr/m-p/430132#M68591</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-01-23T19:43:29Z</dc:date>
    </item>
  </channel>
</rss>

