<?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: Where in SAS can I see whether the sum of residuals is zero in a regression? in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692947#M33435</link>
    <description>&lt;P&gt;Unless you have removed the intercept from the model, the math forces the sum of un-squared residuals to be zero.&lt;/P&gt;</description>
    <pubDate>Tue, 20 Oct 2020 16:33:43 GMT</pubDate>
    <dc:creator>PaigeMiller</dc:creator>
    <dc:date>2020-10-20T16:33:43Z</dc:date>
    <item>
      <title>Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692780#M33419</link>
      <description>&lt;P&gt;I came across a regression model in SAS which does not use an intercept (constant term), and I would like to see whether the model violates the OLS assumption of zero sum of residuals. How can I view if that is the case in SAS?&lt;/P&gt;</description>
      <pubDate>Tue, 20 Oct 2020 07:49:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692780#M33419</guid>
      <dc:creator>adrfinance</dc:creator>
      <dc:date>2020-10-20T07:49:31Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692810#M33420</link>
      <description>&lt;P&gt;This is not an output of any PROC (that I know of). You could save the residuals to an output data set and sum them yourself.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;When you don't use an intercept, the residuals (usually) will NOT usually sum to zero.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;SPAN&gt;I would like to see whether the model violates the OLS assumption of zero sum of residuals&lt;/SPAN&gt;&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;SPAN&gt;Whether or not the residuals sum to zero in this case, this DOES NOT violate the assumptions of OLS. This is not an assumption of OLS. &lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;A better question to ask when you see a regression with no intercept is: what is the logical justification for not using an intercept? That would be a violation of appropriate model building rules if there is no logical justification for this, and a more serious problem (in my mind) than the residuals not summing to zero (which in my mind is meaningless and not worth bothering over).&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Oct 2020 10:45:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692810#M33420</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2020-10-20T10:45:41Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692811#M33421</link>
      <description>the variables are standardized to have zero mean and standard deviation 1. So I assume it is ok not to have an intercept. Right or not?</description>
      <pubDate>Tue, 20 Oct 2020 10:45:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692811#M33421</guid>
      <dc:creator>adrfinance</dc:creator>
      <dc:date>2020-10-20T10:45:03Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692812#M33422</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/300616"&gt;@adrfinance&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;the variables are standardized to have zero mean and standard deviation 1. So I assume it is ok not to have an intercept. Right or not?&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;The justification for not having an intercept &lt;STRONG&gt;in this case&lt;/STRONG&gt; is fine. Of course, if you back-transform the data to the original scale, there is an intercept.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you hadn't standardized the data, then not having an intercept requires justification.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Oct 2020 10:48:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692812#M33422</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2020-10-20T10:48:15Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692814#M33423</link>
      <description>Yes I came across some models where they standardize all the variables and then they run regressions without intercepts. I assume they do these standardizations (0 mean 1 std) in order to be able to run regressions without intercepts in the first place....</description>
      <pubDate>Tue, 20 Oct 2020 10:59:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692814#M33423</guid>
      <dc:creator>adrfinance</dc:creator>
      <dc:date>2020-10-20T10:59:08Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692815#M33424</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/300616"&gt;@adrfinance&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;Yes I came across some models where they standardize all the variables and then they run regressions without intercepts. I assume they do these standardizations (0 mean 1 std) in order to be able to run regressions without intercepts in the first place....&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;My assumption would be that they do the standardizing so that regression coefficients can be compared to one another. I doubt that wanting to run a regression without an intercept is a valid reason for standardizing.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Oct 2020 11:01:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692815#M33424</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2020-10-20T11:01:03Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692816#M33425</link>
      <description>Yes you might be right but I see many models from them without intercepts so I just made that out. Maybe I am wrong though. I always thought that running a model without an intercept is wrong, didn't know about the fact that a zero mean variable would be fine to be used in a regression without a constant term.</description>
      <pubDate>Tue, 20 Oct 2020 11:02:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692816#M33425</guid>
      <dc:creator>adrfinance</dc:creator>
      <dc:date>2020-10-20T11:02:40Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692923#M33432</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/300616"&gt;@adrfinance&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;Yes you might be right but I see many models from them without intercepts so I just made that out. Maybe I am wrong though. I always thought that running a model without an intercept is wrong, didn't know about the fact that a zero mean variable would be fine to be used in a regression without a constant term.&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;There are fields of study that have their own practices for whatever historical reason. So that might be what you are seeing. Sometimes these things can become so&amp;nbsp; embedded in the "culture" that the reasons are lost in the mists of history.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have done OLS regression by hand, meaning pencil and paper. (Admittedly not a lot of records but still...) I can see anything that reduces the steps being considered a "good thing". The process may have survived into the time when computers and software are more flexible just because that was the way it was done years ago.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Oct 2020 15:19:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692923#M33432</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2020-10-20T15:19:59Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692940#M33433</link>
      <description>&lt;P&gt;The "&lt;EM&gt;&lt;STRONG&gt;LS&lt;/STRONG&gt;&lt;/EM&gt;" in OLS is least &lt;EM&gt;&lt;STRONG&gt;squares&lt;/STRONG&gt;&lt;/EM&gt;.&amp;nbsp;&amp;nbsp; That is, the OLS algorithm minimizes the &lt;EM&gt;&lt;STRONG&gt;sum of squared residuals&lt;/STRONG&gt;&lt;/EM&gt;, &lt;STRIKE&gt;which need not even minimize the sum of unsquared residuals, much less set that sum to zero&lt;/STRIKE&gt;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Oops, as &lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/10892"&gt;@PaigeMiller&lt;/a&gt; and &lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/300616"&gt;@adrfinance&lt;/a&gt; pointed out, I need to review my recollection of OLS.&amp;nbsp; Thanks to both.&amp;nbsp; I've editted this post just in case someone doesn't notice the responses.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 21 Oct 2020 03:23:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692940#M33433</guid>
      <dc:creator>mkeintz</dc:creator>
      <dc:date>2020-10-21T03:23:37Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692947#M33435</link>
      <description>&lt;P&gt;Unless you have removed the intercept from the model, the math forces the sum of un-squared residuals to be zero.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Oct 2020 16:33:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692947#M33435</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2020-10-20T16:33:43Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692971#M33436</link>
      <description>I think you need to refresh your econometrics knowledge. take a look here &lt;A href="https://www.statisticshowto.com/residual/#:~:text=The%20sum%20of%20the%20residuals,residuals%20%2F%20the%20number%20of%20items" target="_blank"&gt;https://www.statisticshowto.com/residual/#:~:text=The%20sum%20of%20the%20residuals,residuals%20%2F%20the%20number%20of%20items&lt;/A&gt;.</description>
      <pubDate>Tue, 20 Oct 2020 17:45:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/692971#M33436</guid>
      <dc:creator>adrfinance</dc:creator>
      <dc:date>2020-10-20T17:45:42Z</dc:date>
    </item>
    <item>
      <title>Re: Where in SAS can I see whether the sum of residuals is zero in a regression?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/693058#M33441</link>
      <description>&lt;P&gt;I think you're right.&lt;/P&gt;</description>
      <pubDate>Wed, 21 Oct 2020 03:01:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Where-in-SAS-can-I-see-whether-the-sum-of-residuals-is-zero-in-a/m-p/693058#M33441</guid>
      <dc:creator>mkeintz</dc:creator>
      <dc:date>2020-10-21T03:01:04Z</dc:date>
    </item>
  </channel>
</rss>

