<?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: setting reference levels for variables in proc surveylogistic in SAS Studio</title>
    <link>https://communities.sas.com/t5/SAS-Studio/setting-reference-levels-for-variables-in-proc-surveylogistic/m-p/764965#M10154</link>
    <description>You know, I knew it was gonna be something dumb like that. Thanks!&lt;BR /&gt;&lt;BR /&gt;Can I ask why move the weight statement? Seems to be working fine, and that's how my PI had me do it. Just curious.</description>
    <pubDate>Tue, 31 Aug 2021 00:51:42 GMT</pubDate>
    <dc:creator>joachimg</dc:creator>
    <dc:date>2021-08-31T00:51:42Z</dc:date>
    <item>
      <title>setting reference levels for variables in proc surveylogistic</title>
      <link>https://communities.sas.com/t5/SAS-Studio/setting-reference-levels-for-variables-in-proc-surveylogistic/m-p/764962#M10152</link>
      <description>&lt;P&gt;Okay first of all.....if you saw my last post, no you didn't. ANYWAYS.....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm trying to run a logistic regression with proc surveylogistic and I'm having trouble setting my reference levels for the different variables. Here is my code:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc surveylogistic data=masks1;
weight wt_multi;
class d_age_cat2 (ref=”0”) d_gender (ref=”MALE”) d_race (ref=”NH White”) d_politics (ref=”DEM“) d_religion2 (ref=”NOTHING”) vaxxed (ref=”0”);
model b2_m_always (descending) = d_age_cat2 d_gender d_race d_politics d_religion2 vaxxed;
run;&lt;/CODE&gt;&lt;/PRE&gt;&lt;DIV class="sasError"&gt;And here is the error message I get:&lt;/DIV&gt;&lt;DIV class="sasError"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasError"&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;103        
 104        proc surveylogistic data=masks1;
 105        weight wt_multi;
 106        class d_age_cat2 (ref=”0”) d_gender (ref=”MALE”) d_race (ref=”NH White”) d_politics (ref=”DEM“)
                                  _______                __________              _____                           _________
 _____________                                                                                                                       
                                  22                     22                      22                              22
 22
                                  202                    202                     202                             202
 202
 106      ! d_religion2 (ref=”NOTHING”) vaxxed (ref=”0”);
 106        class d_age_cat2 (ref=”0”) d_gender (ref=”MALE”) d_race (ref=”NH White”) d_politics (ref=”DEM“)
 106      ! d_religion2 (ref=”NOTHING”) vaxxed (ref=”0”);
                                                        _______
                                                        22
 ERROR 22-322: Syntax error, expecting one of the following: a quoted string, FIRST, LAST.  
 
 ERROR 202-322: The option or parameter is not recognized and will be ignored.
 
 106        class d_age_cat2 (ref=”0”) d_gender (ref=”MALE”) d_race (ref=”NH White”) d_politics (ref=”DEM“)
 106      ! d_religion2 (ref=”NOTHING”) vaxxed (ref=”0”);
                                                        _______
                                                        202
 ERROR 202-322: The option or parameter is not recognized and will be ignored.&lt;/CODE&gt;&lt;/PRE&gt;&lt;/DIV&gt;&lt;DIV class="sasError"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasError"&gt;Please help! Proc surveylogistic has been killing me lately. Thanks in advance.&amp;nbsp;&lt;/DIV&gt;</description>
      <pubDate>Tue, 31 Aug 2021 00:08:06 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/setting-reference-levels-for-variables-in-proc-surveylogistic/m-p/764962#M10152</guid>
      <dc:creator>joachimg</dc:creator>
      <dc:date>2021-08-31T00:08:06Z</dc:date>
    </item>
    <item>
      <title>Re: setting reference levels for variables in proc surveylogistic</title>
      <link>https://communities.sas.com/t5/SAS-Studio/setting-reference-levels-for-variables-in-proc-surveylogistic/m-p/764964#M10153</link>
      <description>Did you copy and paste that from&lt;BR /&gt;somewhere? The quotation marks appear a bit messed up - try retyping the code and make sure to use the formatted reference values. Also, put the weight statement after the CLASS statement. &lt;BR /&gt;&lt;BR /&gt;I suspect the only issue is the quotation marks being messed up though.</description>
      <pubDate>Tue, 31 Aug 2021 00:27:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/setting-reference-levels-for-variables-in-proc-surveylogistic/m-p/764964#M10153</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-08-31T00:27:42Z</dc:date>
    </item>
    <item>
      <title>Re: setting reference levels for variables in proc surveylogistic</title>
      <link>https://communities.sas.com/t5/SAS-Studio/setting-reference-levels-for-variables-in-proc-surveylogistic/m-p/764965#M10154</link>
      <description>You know, I knew it was gonna be something dumb like that. Thanks!&lt;BR /&gt;&lt;BR /&gt;Can I ask why move the weight statement? Seems to be working fine, and that's how my PI had me do it. Just curious.</description>
      <pubDate>Tue, 31 Aug 2021 00:51:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/setting-reference-levels-for-variables-in-proc-surveylogistic/m-p/764965#M10154</guid>
      <dc:creator>joachimg</dc:creator>
      <dc:date>2021-08-31T00:51:42Z</dc:date>
    </item>
    <item>
      <title>Re: setting reference levels for variables in proc surveylogistic</title>
      <link>https://communities.sas.com/t5/SAS-Studio/setting-reference-levels-for-variables-in-proc-surveylogistic/m-p/764973#M10155</link>
      <description>I’m in the habit of putting them in the order as it shows in the docs. There’s a few good reasons for this - makes it easier to read your code and if you use patterns for coding updates and fixes are easier. Following the doc order is something most SAS programmers do so its a good way to have consistent clean code. For some procs/statements the order does matter as well, and I can never remember which ones so defaulting to keeping them in order works in general.</description>
      <pubDate>Tue, 31 Aug 2021 02:08:02 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/setting-reference-levels-for-variables-in-proc-surveylogistic/m-p/764973#M10155</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-08-31T02:08:02Z</dc:date>
    </item>
  </channel>
</rss>

