<?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: proc ttest vs proc glm help in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557849#M155576</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/273667"&gt;@michaelm90&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;still having trouble because division and league are not numerical variables&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;I modified my exmaple to include 2 categorical variables. Categorical variables do not need to be numeric.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Map your variables to mine - run the code to see the data first - and then replace the variable names as needed.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If it still doesn't work post your code and log. We can't see what you're doing otherwise or why it may be wrong.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 10 May 2019 15:54:37 GMT</pubDate>
    <dc:creator>Reeza</dc:creator>
    <dc:date>2019-05-10T15:54:37Z</dc:date>
    <item>
      <title>proc ttest vs proc glm help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557796#M155546</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hello, this might be a really basic question, but I am struggling. Please help!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Report the p-value of comparing the average 1987 Salary in $ Thousands (&lt;/SPAN&gt;&lt;EM&gt;SALARY&lt;/EM&gt;&lt;SPAN&gt;) of four levels of League and Division (&lt;/SPAN&gt;&lt;EM&gt;DIV&lt;/EM&gt;&lt;SPAN&gt;). (up to four decimal places, please) using the sas supplied data set sashelp.baseball&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I'm having trouble with this problem. I originally tried using proc ttest but since there are more than two levels I can't. I'm confused on how to use proc glm in this problem.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 15:28:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557796#M155546</guid>
      <dc:creator>michaelm90</dc:creator>
      <dc:date>2019-05-10T15:28:40Z</dc:date>
    </item>
    <item>
      <title>Re: proc ttest vs proc glm help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557818#M155559</link>
      <description>&lt;P&gt;Use PROC ANOVA instead.&lt;/P&gt;
&lt;P&gt;This would test if pain relief was related to the originating pain level which is a categorical variable with 8 levels.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;title1 'Randomized Complete Block With Two Factors';
data PainRelief;
   input PainLevel Codeine Acupuncture Relief @@;
   datalines;
1 1 1 0.0  1 2 1 0.5  1 1 2 0.6  1 2 2 1.2
2 1 1 0.3  2 2 1 0.6  2 1 2 0.7  2 2 2 1.3
3 1 1 0.4  3 2 1 0.8  3 1 2 0.8  3 2 2 1.6
4 1 1 0.4  4 2 1 0.7  4 1 2 0.9  4 2 2 1.5
5 1 1 0.6  5 2 1 1.0  5 1 2 1.5  5 2 2 1.9
6 1 1 0.9  6 2 1 1.4  6 1 2 1.6  6 2 2 2.3
7 1 1 1.0  7 2 1 1.8  7 1 2 1.7  7 2 2 2.1
8 1 1 1.2  8 2 1 1.7  8 1 2 1.6  8 2 2 2.4
;

proc anova data=painrelief;
class painlevel codeine;
model relief = painlevel codeine;
run;quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/273667"&gt;@michaelm90&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;&lt;SPAN&gt;Hello, this might be a really basic question, but I am struggling. Please help!&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Report the p-value of comparing the average 1987 Salary in $ Thousands (&lt;/SPAN&gt;&lt;EM&gt;SALARY&lt;/EM&gt;&lt;SPAN&gt;) of four levels of League and Division (&lt;/SPAN&gt;&lt;EM&gt;DIV&lt;/EM&gt;&lt;SPAN&gt;). (up to four decimal places, please)&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I'm having trouble with this problem. I originally tried using proc ttest but since there are more than two levels I can't. I'm confused on how to use proc glm in this problem.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 15:53:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557818#M155559</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2019-05-10T15:53:24Z</dc:date>
    </item>
    <item>
      <title>Re: proc ttest vs proc glm help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557830#M155566</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/273667"&gt;@michaelm90&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;&lt;SPAN&gt;Hello, this might be a really basic question, but I am struggling. Please help!&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Report the p-value of comparing the average 1987 Salary in $ Thousands (&lt;/SPAN&gt;&lt;EM&gt;SALARY&lt;/EM&gt;&lt;SPAN&gt;) of four levels of League and Division (&lt;/SPAN&gt;&lt;EM&gt;DIV&lt;/EM&gt;&lt;SPAN&gt;). (up to four decimal places, please)&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;I'm having trouble with this problem. I originally tried using proc ttest but since there are more than two levels I can't. I'm confused on how to use proc glm in this problem.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;If you are using the SAS supplied SASHELP.BASEBALL data set you should say so. Then we know what the data looks like.&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 15:26:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557830#M155566</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2019-05-10T15:26:36Z</dc:date>
    </item>
    <item>
      <title>Re: proc ttest vs proc glm help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557831#M155567</link>
      <description>&lt;P&gt;yes, sorry I am using the sas supplied data set sashelp.baseball&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 15:27:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557831#M155567</guid>
      <dc:creator>michaelm90</dc:creator>
      <dc:date>2019-05-10T15:27:38Z</dc:date>
    </item>
    <item>
      <title>Re: proc ttest vs proc glm help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557835#M155570</link>
      <description>&lt;P&gt;In this case (but not in all cases), PROC ANOVA and PROC GLM give the same answers. Generally, I advise people to use PROC GLM and not PROC ANOVA because of the following warning at&amp;nbsp;&lt;A href="https://documentation.sas.com/?cdcId=pgmmvacdc&amp;amp;cdcVersion=9.4&amp;amp;docsetId=statug&amp;amp;docsetTarget=statug_anova_overview.htm&amp;amp;locale=en"&gt;https://documentation.sas.com/?cdcId=pgmmvacdc&amp;amp;cdcVersion=9.4&amp;amp;docsetId=statug&amp;amp;docsetTarget=statug_anova_overview.htm&amp;amp;locale=en&lt;/A&gt;&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="Capture.PNG" style="width: 600px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/29408i37ABA7A0AA35D107/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 15:30:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557835#M155570</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-05-10T15:30:42Z</dc:date>
    </item>
    <item>
      <title>Re: proc ttest vs proc glm help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557840#M155572</link>
      <description>&lt;P&gt;still having trouble because division and league are not numerical variables&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 15:35:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557840#M155572</guid>
      <dc:creator>michaelm90</dc:creator>
      <dc:date>2019-05-10T15:35:34Z</dc:date>
    </item>
    <item>
      <title>Re: proc ttest vs proc glm help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557842#M155573</link>
      <description>&lt;P&gt;If they're not numeric variables, then you put them in the CLASS statement of PROC GLM and in the MODEL statement.&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13879"&gt;@Reeza&lt;/a&gt;&amp;nbsp;gave an example.&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 15:41:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557842#M155573</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2019-05-10T15:41:41Z</dc:date>
    </item>
    <item>
      <title>Re: proc ttest vs proc glm help</title>
      <link>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557849#M155576</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/273667"&gt;@michaelm90&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;still having trouble because division and league are not numerical variables&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;I modified my exmaple to include 2 categorical variables. Categorical variables do not need to be numeric.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Map your variables to mine - run the code to see the data first - and then replace the variable names as needed.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If it still doesn't work post your code and log. We can't see what you're doing otherwise or why it may be wrong.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 10 May 2019 15:54:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/proc-ttest-vs-proc-glm-help/m-p/557849#M155576</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2019-05-10T15:54:37Z</dc:date>
    </item>
  </channel>
</rss>

