06-25-2014 06:25 PM
Can someone give me the position of the Slice Statement in Proc Logistic syntax? I've put it all over the place and I keep getting the above error about invalidity or proper order. I'm using the param=glm option. Thanks, wardodd
06-25-2014 07:29 PM
It would help to show the rest of your syntax as well. Some options may be incompatible with others.
A partial example from online help:
determines how to construct the partition of the least squares means for the model-effect. A slice-specification consists of an effect name followed by an optional list of formatted values. For example, the following statements creates partitions of the A*B interaction effect for all levels of variable A:
class a b; model y = a b a*b; slice a*b / sliceby=a;
Similar to use of LSMEANS
06-25-2014 09:21 PM
Here's my code:
proc logistic data = test ;
class gender_code (ref='M') const (ref='1') back (ref='1')/param=glm;
model employed1 (event='1') = const back gender_code gender_code*back gender_code*const const*back/ rsq lackfit;
slice const*back/sliceby back;
06-25-2014 09:43 PM
Curious. The code you posted here is different from that which came by e-mail. The PARAM=GLM is required for the SLICE statement to be valid. Perhaps you could post your log, as something strange is going on.
06-26-2014 03:18 PM
I pasted the wrong code at first (had param=ref) and edited it after I posted it. The log is vague - it just says it's invalid or is not in the proper order. Weird. I wonder if it's a patch thing or version issue.
06-27-2014 09:44 AM
Unless you are operating on a version earlier than 9.2, I doubt that it is a version issue. Try:
slice const*back/sliceby = back;
It may be that the syntax requires the equals sign in the sliceby option.