<?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 How to run proc glm on with means of categories as the outcome in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-run-proc-glm-on-with-means-of-categories-as-the-outcome/m-p/799146#M314209</link>
    <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm working on my thesis and having some trouble figuring out how to run an analysis. I have quintiles of weight change over a 10 year period for a population of about 10,000. I'm looking to run a general linear model with the mean weight change across each quintile as the outcome, but am unsure how to create an outcome variable for this. I am able to find the means weight change across the quintiles, but figuring out how to make those into the outcome variable appropriately is where I'm having some trouble. Any ideas? Thanks!&lt;/P&gt;</description>
    <pubDate>Mon, 28 Feb 2022 15:34:04 GMT</pubDate>
    <dc:creator>Corinthian94</dc:creator>
    <dc:date>2022-02-28T15:34:04Z</dc:date>
    <item>
      <title>How to run proc glm on with means of categories as the outcome</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-run-proc-glm-on-with-means-of-categories-as-the-outcome/m-p/799146#M314209</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm working on my thesis and having some trouble figuring out how to run an analysis. I have quintiles of weight change over a 10 year period for a population of about 10,000. I'm looking to run a general linear model with the mean weight change across each quintile as the outcome, but am unsure how to create an outcome variable for this. I am able to find the means weight change across the quintiles, but figuring out how to make those into the outcome variable appropriately is where I'm having some trouble. Any ideas? Thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 28 Feb 2022 15:34:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-run-proc-glm-on-with-means-of-categories-as-the-outcome/m-p/799146#M314209</guid>
      <dc:creator>Corinthian94</dc:creator>
      <dc:date>2022-02-28T15:34:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to run proc glm on with means of categories as the outcome</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-run-proc-glm-on-with-means-of-categories-as-the-outcome/m-p/799149#M314210</link>
      <description>&lt;P&gt;If you use all 10,000 observations, and the weight change for each observation, then GLM will predict the average weight change in each quintile. (That isn't exactly what you asked for, but it seems to me to be the most sensible approach). Although its not really clear to me the point of modeling a weight change against the quintile of that weight change.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Example using a data set of 12 observations&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data have;
    input id quintile weight;
    cards;
1 1 29
2 1 35
3 1 34
4 2 40
5 2 44
6 2 49
7 3 50
8 3 50
9 4 55
10 4 60
11 5 61
12 5 66
;

proc glm data=have;
    class quintile;
    model weight=quintile;
    means quintile;
run;
quit;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, I don't really understand this sentence (especially the part that says "mean weight change across each quintile", what is that? Did you really mean to say "mean weight change &lt;FONT color="#FF0000"&gt;within&lt;/FONT&gt; each quintile"?):&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;SPAN&gt;I'm looking to run a general linear model with the mean weight change across each quintile as the outcome&lt;/SPAN&gt;&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;</description>
      <pubDate>Mon, 28 Feb 2022 16:14:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-run-proc-glm-on-with-means-of-categories-as-the-outcome/m-p/799149#M314210</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2022-02-28T16:14:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to run proc glm on with means of categories as the outcome</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-run-proc-glm-on-with-means-of-categories-as-the-outcome/m-p/799165#M314217</link>
      <description>To the last question - yes! That's exactly what I meant. I was using my advisors phrasing, but can see how that would be confusing. That makes sense though, I utilized that code and it did exactly what you said. I'm admittedly much less experienced with proc glm than logistic or reg, so I was not even aware means was an option for it. Thank you for the help!</description>
      <pubDate>Mon, 28 Feb 2022 16:27:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-run-proc-glm-on-with-means-of-categories-as-the-outcome/m-p/799165#M314217</guid>
      <dc:creator>Corinthian94</dc:creator>
      <dc:date>2022-02-28T16:27:15Z</dc:date>
    </item>
  </channel>
</rss>

