<?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: Output Proc Freq Measures to a dataset in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Output-Proc-Freq-Measures-to-a-dataset/m-p/424682#M68222</link>
    <description>&lt;P&gt;You can use ODS OUTPUT.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc freq data=sashelp.cars;
table type*(origin drivetrain cylinders) / out=want measures;
ods output measures=want2;
run;

proc print data=want;
proc print data=want2;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/iml/2017/01/09/ods-output-any-statistic.html" target="_blank"&gt;https://blogs.sas.com/content/iml/2017/01/09/ods-output-any-statistic.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/184743"&gt;@cmtad&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;I'd like to output the Pearson and Spearman coefficients that are provided in the proc freq measures option output to a dataset. &amp;nbsp;I'm comparing the association between a number of variables.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The code is a simple proc freq.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc freq data=set;&lt;/P&gt;
&lt;P&gt;table var1*(var2 var3 var4 var5 var6)/measures;&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is there a way to save the Pearson and Spearman coefficients from the measures output to a dataset? &amp;nbsp;Ultimately, I'd like to create an ordered list of var2-var6 based on their Pearson and Spearman coefficients.&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 03 Jan 2018 19:13:03 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2018-01-03T19:13:03Z</dc:date>
    <item>
      <title>Output Proc Freq Measures to a dataset</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-Proc-Freq-Measures-to-a-dataset/m-p/424677#M68220</link>
      <description>&lt;P&gt;I'd like to output the Pearson and Spearman coefficients that are provided in the proc freq measures option output to a dataset. &amp;nbsp;I'm comparing the association between a number of variables.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The code is a simple proc freq.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc freq data=set;&lt;/P&gt;&lt;P&gt;table var1*(var2 var3 var4 var5 var6)/measures;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a way to save the Pearson and Spearman coefficients from the measures output to a dataset? &amp;nbsp;Ultimately, I'd like to create an ordered list of var2-var6 based on their Pearson and Spearman coefficients.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jan 2018 19:09:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-Proc-Freq-Measures-to-a-dataset/m-p/424677#M68220</guid>
      <dc:creator>cmtad</dc:creator>
      <dc:date>2018-01-03T19:09:32Z</dc:date>
    </item>
    <item>
      <title>Re: Output Proc Freq Measures to a dataset</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-Proc-Freq-Measures-to-a-dataset/m-p/424682#M68222</link>
      <description>&lt;P&gt;You can use ODS OUTPUT.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc freq data=sashelp.cars;
table type*(origin drivetrain cylinders) / out=want measures;
ods output measures=want2;
run;

proc print data=want;
proc print data=want2;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;A href="https://blogs.sas.com/content/iml/2017/01/09/ods-output-any-statistic.html" target="_blank"&gt;https://blogs.sas.com/content/iml/2017/01/09/ods-output-any-statistic.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/184743"&gt;@cmtad&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;I'd like to output the Pearson and Spearman coefficients that are provided in the proc freq measures option output to a dataset. &amp;nbsp;I'm comparing the association between a number of variables.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The code is a simple proc freq.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;proc freq data=set;&lt;/P&gt;
&lt;P&gt;table var1*(var2 var3 var4 var5 var6)/measures;&lt;/P&gt;
&lt;P&gt;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is there a way to save the Pearson and Spearman coefficients from the measures output to a dataset? &amp;nbsp;Ultimately, I'd like to create an ordered list of var2-var6 based on their Pearson and Spearman coefficients.&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jan 2018 19:13:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-Proc-Freq-Measures-to-a-dataset/m-p/424682#M68222</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-01-03T19:13:03Z</dc:date>
    </item>
    <item>
      <title>Re: Output Proc Freq Measures to a dataset</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-Proc-Freq-Measures-to-a-dataset/m-p/424683#M68223</link>
      <description>&lt;P&gt;ODS OUTPUT is the way to go.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;ods trace on;
ods output measures=measures;
proc freq data=sashelp.class;

table sex*(height weight)/measures;

run;
ods trace off;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;I leave the ODS TRACE ON statements there so you can see how to get the name.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jan 2018 19:13:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-Proc-Freq-Measures-to-a-dataset/m-p/424683#M68223</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2018-01-03T19:13:25Z</dc:date>
    </item>
    <item>
      <title>Re: Output Proc Freq Measures to a dataset</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-Proc-Freq-Measures-to-a-dataset/m-p/424691#M68228</link>
      <description>&lt;P&gt;Thanks so much, both of these solutions worked for me.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jan 2018 19:29:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-Proc-Freq-Measures-to-a-dataset/m-p/424691#M68228</guid>
      <dc:creator>cmtad</dc:creator>
      <dc:date>2018-01-03T19:29:50Z</dc:date>
    </item>
  </channel>
</rss>

