<?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 Extracting variables from statistical results for use in other calculations in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473222#M121405</link>
    <description>&lt;P&gt;Greetings!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I frequently use proc GLM for repeated measures ANOVA and more recently proc corr for correlational work.&amp;nbsp; In the case of proc GLM I would like to extract various sums of squares and degrees of freedom for other calculations, such power, effect size or ICC.&amp;nbsp; In the case of the proc corr I would like to extract specific correlations in a matrix for further calculations such as confidence intervals or hypothesis testing of different correlation coefficients.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a reference(s) where I can learn how to do this.&amp;nbsp; Or a website of examples I can use to learn how to do this type of programming.&amp;nbsp; I am getting bits and pieces as I search the web but there are gaps that make it impossible for me to figure it out on my own.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Wishes,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;dg&lt;/P&gt;</description>
    <pubDate>Tue, 26 Jun 2018 02:16:51 GMT</pubDate>
    <dc:creator>dgabriel</dc:creator>
    <dc:date>2018-06-26T02:16:51Z</dc:date>
    <item>
      <title>Extracting variables from statistical results for use in other calculations</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473222#M121405</link>
      <description>&lt;P&gt;Greetings!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I frequently use proc GLM for repeated measures ANOVA and more recently proc corr for correlational work.&amp;nbsp; In the case of proc GLM I would like to extract various sums of squares and degrees of freedom for other calculations, such power, effect size or ICC.&amp;nbsp; In the case of the proc corr I would like to extract specific correlations in a matrix for further calculations such as confidence intervals or hypothesis testing of different correlation coefficients.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a reference(s) where I can learn how to do this.&amp;nbsp; Or a website of examples I can use to learn how to do this type of programming.&amp;nbsp; I am getting bits and pieces as I search the web but there are gaps that make it impossible for me to figure it out on my own.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Wishes,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;dg&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jun 2018 02:16:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473222#M121405</guid>
      <dc:creator>dgabriel</dc:creator>
      <dc:date>2018-06-26T02:16:51Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting variables from statistical results for use in other calculations</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473223#M121406</link>
      <description>&lt;P&gt;you mean using ods?: &lt;A href="https://analytics.ncsu.edu/sesug/2002/PS03.pdf" target="_blank"&gt;https://analytics.ncsu.edu/sesug/2002/PS03.pdf&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jun 2018 02:28:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473223#M121406</guid>
      <dc:creator>pau13rown</dc:creator>
      <dc:date>2018-06-26T02:28:40Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting variables from statistical results for use in other calculations</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473224#M121407</link>
      <description>&lt;P&gt;Hello.&amp;nbsp; Thank you.&amp;nbsp; That looks pretty darn close.&amp;nbsp; I will have to read it tomorrow morning.&amp;nbsp; Once the variables are extracted, examples have thing "&amp;amp;" in front of the extracted variables and&amp;nbsp;the word "symput".&amp;nbsp; &amp;nbsp;The link is one missing piece; that is, how to identify them to extract them.&amp;nbsp; Thanks once again.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;dg&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jun 2018 02:56:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473224#M121407</guid>
      <dc:creator>dgabriel</dc:creator>
      <dc:date>2018-06-26T02:56:48Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting variables from statistical results for use in other calculations</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473229#M121409</link>
      <description>&lt;P&gt;a very common example is when we need to give the sample size (n) in the table column headings. The code would be something like this (we use "&amp;amp;" because we are making the statistic a macro variable so we can use it elsewhere eg when creating the table or figure):&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ods output onewayfreqs=getn;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;proc&lt;/STRONG&gt; &lt;STRONG&gt;freq&lt;/STRONG&gt; data=temp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; tables treatment;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;run&lt;/STRONG&gt;;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;data&lt;/STRONG&gt; _null_;&lt;/P&gt;&lt;P&gt;&amp;nbsp; set getn;&lt;/P&gt;&lt;P&gt;&amp;nbsp; if treatment=&lt;STRONG&gt;1&lt;/STRONG&gt; then call symput("trt11",strip(put(frequency,&lt;STRONG&gt;2.&lt;/STRONG&gt;)));&lt;/P&gt;&lt;P&gt;&amp;nbsp; else if treatment=&lt;STRONG&gt;2&lt;/STRONG&gt; then call symput("trt2",strip(put(frequency,&lt;STRONG&gt;2.&lt;/STRONG&gt;)));&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;run&lt;/STRONG&gt;;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;proc&lt;/STRONG&gt; &lt;STRONG&gt;report&lt;/STRONG&gt; data=....;&lt;/P&gt;&lt;P&gt;&amp;nbsp; column .... trt1 trt2 ....;&lt;/P&gt;&lt;P&gt;:&lt;/P&gt;&lt;P&gt;&amp;nbsp; define trt1 / display width=&lt;STRONG&gt;10&lt;/STRONG&gt; right "Treatment 1 (n=&amp;amp;trt1)";&lt;/P&gt;&lt;P&gt;&amp;nbsp; define trt2 / display width=&lt;STRONG&gt;10&lt;/STRONG&gt; right "Treatment 2 (n=&amp;amp;trt2)";&lt;/P&gt;&lt;P&gt;:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;run&lt;/STRONG&gt;;&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jun 2018 03:54:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473229#M121409</guid>
      <dc:creator>pau13rown</dc:creator>
      <dc:date>2018-06-26T03:54:58Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting variables from statistical results for use in other calculations</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473233#M121411</link>
      <description>&lt;P&gt;If you see the required value in the procedure output, you can get it in an ODS table. Check the Details section of the procedure documentation&amp;nbsp;for the ODS Table Names topic. Add the statement&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ODS OUTPUT procTablename=myTableName;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;to your code and look at the table contents. The value will be there somewhere.&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jun 2018 04:25:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473233#M121411</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2018-06-26T04:25:03Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting variables from statistical results for use in other calculations</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473237#M121413</link>
      <description>&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;</description>
      <pubDate>Tue, 26 Jun 2018 04:52:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473237#M121413</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-06-26T04:52:13Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting variables from statistical results for use in other calculations</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473304#M121440</link>
      <description>&lt;P&gt;PaulBrown,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The example&amp;nbsp;is exactly the type of thing talking about.&amp;nbsp; I can read the code and see exactly what what you are doing.&amp;nbsp; I have been using SAS for a long time but only for straight forward text book examples.&amp;nbsp; No coding.&amp;nbsp; I so most of my data manipulation like that in MATLAB which learned it organically over 30 years.&amp;nbsp; Now, I am trying to do the same with SAS programming to minimize&amp;nbsp;going back and fourth between programs.&amp;nbsp; That is, use SAS for statistics then type in the results into code written MATLAB for further analysis.&amp;nbsp; The code below illustrates what I am trying to accomplish from beginning to end.&amp;nbsp; Now, I have to apply to ANOVA and correlational work.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best Wishes,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;dg&lt;/P&gt;</description>
      <pubDate>Tue, 26 Jun 2018 11:01:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473304#M121440</guid>
      <dc:creator>dgabriel</dc:creator>
      <dc:date>2018-06-26T11:01:33Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting variables from statistical results for use in other calculations</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473308#M121443</link>
      <description>Thank is a great reference for the thing I am trying to do.&lt;BR /&gt;&lt;BR /&gt;dg</description>
      <pubDate>Tue, 26 Jun 2018 11:04:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473308#M121443</guid>
      <dc:creator>dgabriel</dc:creator>
      <dc:date>2018-06-26T11:04:56Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting variables from statistical results for use in other calculations</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473313#M121444</link>
      <description>Thank you very much.&lt;BR /&gt;&lt;BR /&gt;dg</description>
      <pubDate>Tue, 26 Jun 2018 11:05:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Extracting-variables-from-statistical-results-for-use-in-other/m-p/473313#M121444</guid>
      <dc:creator>dgabriel</dc:creator>
      <dc:date>2018-06-26T11:05:12Z</dc:date>
    </item>
  </channel>
</rss>

