<?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 can i have a variable 'R' in Model statement? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/463963#M118270</link>
    <description>&lt;P&gt;hello one of the variables in my dataset is just 'R'. I'm and trying to fit a few log-linear models but whenever i type in 'R' either alone or within an interaction term it turns blue. i looked it up and see that under the Model statement, R requests analysis of residuals. However my output seems like what is should be for the GENMOD procedure i ran and there are no plots/tables referencing residuals. In my analysis of maximum likelihood tables, the reference level of 'R' is correct referenced &amp;nbsp;so it appears that it worked as it should have&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But i'm just worried that my values are off. Does anyone know if this disrupts my output values?&lt;/P&gt;&lt;P&gt;Here is my code but on here it doesn't color it the way it is on my computer. Everything is the same expect the two 'r' in the interaction terms are blue.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc genmod data=lm.hw4q1;
class m (ref='No') i (ref='No') r (ref= 'West') /param=reference;
model count = r m i i*&lt;FONT color="#0000FF"&gt;r&lt;/FONT&gt; m*&lt;FONT color="#0000FF"&gt;r&lt;/FONT&gt; /dist=Poisson;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 22 May 2018 06:19:54 GMT</pubDate>
    <dc:creator>iressa131</dc:creator>
    <dc:date>2018-05-22T06:19:54Z</dc:date>
    <item>
      <title>can i have a variable 'R' in Model statement?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/463963#M118270</link>
      <description>&lt;P&gt;hello one of the variables in my dataset is just 'R'. I'm and trying to fit a few log-linear models but whenever i type in 'R' either alone or within an interaction term it turns blue. i looked it up and see that under the Model statement, R requests analysis of residuals. However my output seems like what is should be for the GENMOD procedure i ran and there are no plots/tables referencing residuals. In my analysis of maximum likelihood tables, the reference level of 'R' is correct referenced &amp;nbsp;so it appears that it worked as it should have&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But i'm just worried that my values are off. Does anyone know if this disrupts my output values?&lt;/P&gt;&lt;P&gt;Here is my code but on here it doesn't color it the way it is on my computer. Everything is the same expect the two 'r' in the interaction terms are blue.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc genmod data=lm.hw4q1;
class m (ref='No') i (ref='No') r (ref= 'West') /param=reference;
model count = r m i i*&lt;FONT color="#0000FF"&gt;r&lt;/FONT&gt; m*&lt;FONT color="#0000FF"&gt;r&lt;/FONT&gt; /dist=Poisson;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 May 2018 06:19:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/463963#M118270</guid>
      <dc:creator>iressa131</dc:creator>
      <dc:date>2018-05-22T06:19:54Z</dc:date>
    </item>
    <item>
      <title>Re: can i have a variable 'R' in Model statement?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/463966#M118273</link>
      <description>&lt;P&gt;Have you tried to rename the variable R ?&lt;/P&gt;
&lt;P&gt;(I'm not familiar with that proc and hope I have renamed the right Rs in your code)&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc genmod data=lm.hw4q1 (rename=(R=myR));
class m (ref='No') i (ref='No') myr (ref= 'West') /param=reference;
model count = myr m i i*myr m*myr /dist=Poisson;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 22 May 2018 06:29:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/463966#M118273</guid>
      <dc:creator>Shmuel</dc:creator>
      <dc:date>2018-05-22T06:29:40Z</dc:date>
    </item>
    <item>
      <title>Re: can i have a variable 'R' in Model statement?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/463986#M118280</link>
      <description>&lt;P&gt;The Enhanced Editor is not perfect in its decisions when to use which color, so it can interpret your variable name wrongly as an option (that would be used in a slightly other place like following a forward slash).&lt;/P&gt;
&lt;P&gt;From my experience, as long as the log looks like it should, you are OK.&lt;/P&gt;</description>
      <pubDate>Tue, 22 May 2018 09:01:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/463986#M118280</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2018-05-22T09:01:29Z</dc:date>
    </item>
    <item>
      <title>Re: can i have a variable 'R' in Model statement?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/464011#M118291</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/11562"&gt;@Kurt_Bremser&lt;/a&gt;&amp;nbsp;is correct about the editor and how it colors keywords.&amp;nbsp; If the token is a valid keyword in the context of the statement, it gets the keyword color treatment.&amp;nbsp; But ultimately it's the SAS language processor that decides how to interpret it.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want to be more explicit about this as a variable name, you can try the literal syntax -- but I'm not sure it makes this more readable:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc genmod data=lm.hw4q1;
class m (ref='No') i (ref='No') 'r'n (ref= 'West') /param=reference;
model count = 'r'n m i i*'r'n m*'r'n /dist=Poisson;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 22 May 2018 11:40:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/464011#M118291</guid>
      <dc:creator>ChrisHemedinger</dc:creator>
      <dc:date>2018-05-22T11:40:22Z</dc:date>
    </item>
    <item>
      <title>Re: can i have a variable 'R' in Model statement?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/464067#M118303</link>
      <description>&lt;P&gt;The "R" to request residuals is an option which would go after the /. If you were to include in in your model the statement would be:&lt;/P&gt;
&lt;PRE&gt;model count = r m i i*r m*r /  dist=Poisson  R;
&lt;/PRE&gt;
&lt;P&gt;So there should be no problem with a variable named R or Poisson or Pred or any of the other options. Though the code might appear somewhat misleading ...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 22 May 2018 14:33:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/can-i-have-a-variable-R-in-Model-statement/m-p/464067#M118303</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-05-22T14:33:32Z</dc:date>
    </item>
  </channel>
</rss>

