LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (December 2010, week 3)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Tue, 21 Dec 2010 09:58:19 -0500
Reply-To:     bbser 2009 <bbser2009@GMAIL.COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         bbser 2009 <bbser2009@GMAIL.COM>
Subject:      what's wrong with proc means?
Content-Type: text/plain; charset="US-ASCII"

Greetings!

Running the code below, I ended up with the output data set like this:

chol _TYPE_ _FREQ_ ... Missing 0 11 Low 1 6 High 1 5

Notice the "grand mean" line starts with "Missing". Why?

If you change the class statement in the proc means below to this one:

class chol/missing;

Then there are two lines led by "Missing" like below. Why again?

chol _TYPE_ _FREQ_ ... Missing 0 15 Missing 1 4 Low 1 6 High 1 5

Thank you very much.

Max

---------- code -------------------

data blood; input subject rbc wbc chol; cards; 1 7.4 7710 258 2 4.7 6560 . 3 7.53 5690 184 4 6.85 6680 . 5 7.72 . 187 6 3.69 6140 142 7 4.78 6550 290 8 4.96 5200 151 9 5.66 . 311 10 5.55 7710 . 11 5.62 . 152 12 5.85 7410 241 13 4.37 5780 . 14 6.94 5590 152 15 6.03 6520 217 ; *proc print data=blood; *run;

proc format; value chol_group low -< 200 = 'Low' 200 - high = 'High' .="Missing"; run;

title "proc means, output data set, class Chol/missing;"; proc means data=blood mean maxdec=1 noprint; class Chol; format Chol chol_group.; var RBC WBC; output out=temp mean= / autoname; run;

proc print data=temp noobs; run;


Back to: Top of message | Previous page | Main SAS-L page