<?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: GLM Error Message in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449016#M69638</link>
    <description>All the variables in the code are also in the work.allerk data file. And they all have a value. That's why I'm so clueless about what to do.</description>
    <pubDate>Tue, 27 Mar 2018 15:26:09 GMT</pubDate>
    <dc:creator>fawink</dc:creator>
    <dc:date>2018-03-27T15:26:09Z</dc:date>
    <item>
      <title>GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/448986#M69630</link>
      <description>&lt;P&gt;Dear people&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am currently working on my master thesis with SAS and want to calculate a GLM. My goal is to check, which RK have an influence of the result in RKSchu.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I wrote&amp;nbsp;this code:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;DATA Allehypo Verurteilte Freigesprochen Lebend Todesstrafe Teil1 Teil2;&lt;BR /&gt;SET MASTER.SERIE3HYPO MASTER.SERIE3RK;&lt;/P&gt;&lt;P&gt;PROC GLM;&lt;BR /&gt;CLASS RKSchu;&lt;BR /&gt;MODEL RKSchu = RK1 RK3 RK4 RK5 RK6 RK7 RK8 RK9 RK11 RK12 RK13 RK17;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;But I allay get the following error:&amp;nbsp;&lt;/P&gt;&lt;DIV class="sasError"&gt;ERROR: One or more variables are missing or freq or weight is zero on every observation.&lt;/DIV&gt;&lt;DIV class="sasError"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasError"&gt;Someone around who could help me with this?&lt;/DIV&gt;&lt;DIV class="sasError"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="sasError"&gt;Thank you in advance and best regards from Switzerland!&lt;/DIV&gt;</description>
      <pubDate>Tue, 27 Mar 2018 14:26:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/448986#M69630</guid>
      <dc:creator>fawink</dc:creator>
      <dc:date>2018-03-27T14:26:30Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/448995#M69631</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/199462"&gt;@fawink&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="sasError"&gt;ERROR: One or more variables are missing or freq or weight is zero on every observation.&lt;/DIV&gt;
&lt;DIV class="sasError"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Actually look at your data. Then the meaning of the error message ought to be clear. At least one of your variables is all missing.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, your code is poorly written, when you write this DATA statement, you create seven data sets at once, they are identical to each other, and there's no reason to do this.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;DATA Allehypo Verurteilte Freigesprochen Lebend Todesstrafe Teil1 Teil2;
SET MASTER.SERIE3HYPO MASTER.SERIE3RK;

PROC GLM;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Mar 2018 15:09:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/448995#M69631</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2018-03-27T15:09:50Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/448999#M69632</link>
      <description>&lt;P&gt;You're running a GLM model with a categorical outcome?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't think that's correct, you likely should be using a different type of analysis.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/199462"&gt;@fawink&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;Dear people&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am currently working on my master thesis with SAS and want to calculate a GLM. My goal is to check, which RK have an influence of the result in RKSchu.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I wrote&amp;nbsp;this code:&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;DATA Allehypo Verurteilte Freigesprochen Lebend Todesstrafe Teil1 Teil2;&lt;BR /&gt;SET MASTER.SERIE3HYPO MASTER.SERIE3RK;&lt;/P&gt;
&lt;P&gt;PROC GLM;&lt;BR /&gt;CLASS RKSchu;&lt;BR /&gt;MODEL RKSchu = RK1 RK3 RK4 RK5 RK6 RK7 RK8 RK9 RK11 RK12 RK13 RK17;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But I allay get the following error:&amp;nbsp;&lt;/P&gt;
&lt;DIV class="sasError"&gt;ERROR: One or more variables are missing or freq or weight is zero on every observation.&lt;/DIV&gt;
&lt;DIV class="sasError"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasError"&gt;Someone around who could help me with this?&lt;/DIV&gt;
&lt;DIV class="sasError"&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV class="sasError"&gt;Thank you in advance and best regards from Switzerland!&lt;/DIV&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Mar 2018 14:46:34 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/448999#M69632</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-03-27T14:46:34Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449003#M69633</link>
      <description>&lt;P&gt;Thank you for your reply.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I changed the code to:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;DATA WORK.ALLERK ;&lt;BR /&gt;SET WORK.ALLERK ;&lt;/P&gt;&lt;P&gt;PROC GLM;&lt;BR /&gt;CLASS RKSchu ;&lt;BR /&gt;MODEL RKSchu = RK1 RK3 RK4 RK5 RK6 RK7 RK8 RK9 RK11 RK12 RK13 RK17;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I still get the same Error Report.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Where should my variables be missing? They are in the file WORK.ALLERK.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm sorry if I can't explain myself very clearly, English isn't my first language...&lt;/P&gt;</description>
      <pubDate>Tue, 27 Mar 2018 14:55:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449003#M69633</guid>
      <dc:creator>fawink</dc:creator>
      <dc:date>2018-03-27T14:55:50Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449004#M69634</link>
      <description>Thank you for your input, Reza. What would be my alternative?&lt;BR /&gt;&lt;BR /&gt;I'm sorry for the question, but statistics is not my strength...</description>
      <pubDate>Tue, 27 Mar 2018 14:57:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449004#M69634</guid>
      <dc:creator>fawink</dc:creator>
      <dc:date>2018-03-27T14:57:48Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449006#M69635</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/199462"&gt;@fawink&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;Thank you for your reply.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I changed the code to:&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;DATA WORK.ALLERK ;&lt;BR /&gt;SET WORK.ALLERK ;&lt;/P&gt;
&lt;P&gt;PROC GLM;&lt;BR /&gt;CLASS RKSchu ;&lt;BR /&gt;MODEL RKSchu = RK1 RK3 RK4 RK5 RK6 RK7 RK8 RK9 RK11 RK12 RK13 RK17;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT color="#0000ff" size="5"&gt;I still get the same Error Report.&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Where should my variables be missing? They are in the file WORK.ALLERK.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm sorry if I can't explain myself very clearly, English isn't my first language...&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Please post the log with the code and the errors. Paste the lines copied from the log into a code box opened using the forum's {I} menu icon to preserve error text formatting. The message boxes here will reformat text moving error diagnostic characters.&lt;/P&gt;</description>
      <pubDate>Tue, 27 Mar 2018 15:03:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449006#M69635</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-03-27T15:03:27Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449008#M69636</link>
      <description>&lt;P&gt;Thank you, this is the complete log:&amp;nbsp;&lt;/P&gt;&lt;PRE&gt; 75         
 76         DATA  WORK.ALLERK ;
 77         SET     WORK.ALLERK ;
 78         
 
 NOTE: There were 2280 observations read from the data set WORK.ALLERK.
 NOTE: The data set WORK.ALLERK has 2280 observations and 110 variables.
 NOTE: DATA statement used (Total process time):
       real time           0.01 seconds
       cpu time            0.01 seconds
       
 
 79         PROC GLM;
 80         CLASS RKSchu ;
 81         MODEL RKSchu = RK1 RK3 RK4 RK5 RK6 RK7 RK8 RK9 RK11 RK12 RK13 RK17;
 82         
 83         
 84         
 85         OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
 ERROR: One or more variables are missing or freq or weight is zero on every observation.
 98         &lt;/PRE&gt;</description>
      <pubDate>Tue, 27 Mar 2018 15:06:16 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449008#M69636</guid>
      <dc:creator>fawink</dc:creator>
      <dc:date>2018-03-27T15:06:16Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449012#M69637</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/199462"&gt;@fawink&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;Thank you for your reply.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I changed the code to:&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;DATA WORK.ALLERK ;&lt;BR /&gt;SET WORK.ALLERK ;&lt;/P&gt;
&lt;P&gt;PROC GLM;&lt;BR /&gt;CLASS RKSchu ;&lt;BR /&gt;MODEL RKSchu = RK1 RK3 RK4 RK5 RK6 RK7 RK8 RK9 RK11 RK12 RK13 RK17;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I still get the same Error Report.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Where should my variables be missing? They are in the file WORK.ALLERK.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm sorry if I can't explain myself very clearly, English isn't my first language...&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You didn't do the first thing I said to do.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Actually look at your data. Look at work.allerk. What do you see? Is one of the variable all missing?&lt;/P&gt;</description>
      <pubDate>Tue, 27 Mar 2018 15:15:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449012#M69637</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2018-03-27T15:15:00Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449016#M69638</link>
      <description>All the variables in the code are also in the work.allerk data file. And they all have a value. That's why I'm so clueless about what to do.</description>
      <pubDate>Tue, 27 Mar 2018 15:26:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449016#M69638</guid>
      <dc:creator>fawink</dc:creator>
      <dc:date>2018-03-27T15:26:09Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449018#M69639</link>
      <description>&lt;P&gt;Run the following and post the output please, it will show how many missings you actually have in your data.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc format ;
	value $ missfmt ' '="Missing" other="Not Missing";
	value nmissfmt .="Missing" other="Not Missing";
run;

*Proc freq to count missing/non missing;
ods table onewayfreqs=temp;

proc freq data=allerk;
	table _all_ / missing;
	format _numeric_ nmissfmt. _character_ $missfmt.;
run;

*Format output;

data long;
	length variable $32. variable_value $50.;
	set temp;
	Variable=scan(table, 2);
	Variable_Value=strip(trim(vvaluex(variable)));
	presentation=catt(frequency, " (", trim(put(percent/100, percent7.1)), ")");
	keep variable variable_value frequency percent cum: presentation;
	label variable='Variable' variable_value='Variable Value';
run;

proc sort data=long;
	by variable;
run;

proc transpose data=long out=want;
	by variable;
	id variable_value;
	var presentation;
run;&lt;BR /&gt;&lt;BR /&gt;proc print data=want;&lt;BR /&gt;run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Post the results from the WANT data set.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Note that your GLM statement doesn't point to a data set whichcould be problematic if you're not always running your code from the start. The same with using the same data set name in the DATA and SET statement.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data allwerk; *&amp;lt;- if there is a mistake in this step it can destroy your original data and then you'll get errors;
set allwerk;


proc glm; *NO DATA= statement????;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 27 Mar 2018 15:31:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449018#M69639</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-03-27T15:31:28Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449036#M69640</link>
      <description>&lt;P&gt;Thank you soooo, sooo much, I think I found the mistake. There really is a lot of data missing.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;IMG src="blob:https://communities.sas.com/966acff0-907e-4cf3-8084-59f7bb5ebb6c" border="0" width="402" height="510" /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I checked the data again, I found that every person has 10 lines, like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;IMG src="blob:https://communities.sas.com/c8b6bb4f-1aef-4e7a-9bd1-a47aeb828904" border="0" width="550" height="469" /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I assume thats where the error comes from, because very person should just have one line, right?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I got this data from my tutor. Any tips how I can just 'delete' the other lines?&lt;/P&gt;</description>
      <pubDate>Tue, 27 Mar 2018 15:51:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449036#M69640</guid>
      <dc:creator>fawink</dc:creator>
      <dc:date>2018-03-27T15:51:35Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449039#M69641</link>
      <description>&lt;P&gt;It depends, but cleaning the data is an import step that should never be skipped.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;First run a PROC FREQ without the formats I have and PROC MEANS and examine your data thoroughly.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Depending on your data you may need to combine rows rather than just delete rows, unless for some reason all the data in those rows is missing. You can use CMISS and NMISS to count missing values.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Mar 2018 15:54:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449039#M69641</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-03-27T15:54:46Z</dc:date>
    </item>
    <item>
      <title>Re: GLM Error Message</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449047#M69642</link>
      <description>&lt;P&gt;Are your RK1 RK3 RK4 RK5 RK6 RK7 RK8 RK9 RK11 RK12 RK13 RK17 variables measurements from different time periods,&amp;nbsp;different&amp;nbsp;locations/plots/samples or similar? Is it possible that the "missing" values were something like a zero value that was not recorded?&lt;/P&gt;
&lt;P&gt;Or can you describe why you have so many missing values?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 27 Mar 2018 16:06:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/GLM-Error-Message/m-p/449047#M69642</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2018-03-27T16:06:14Z</dc:date>
    </item>
  </channel>
</rss>

