proc genmod data= ;

class ;

model y = x / dist= link= type3 ;

repeated subject= / corr= type= ;

lsmeans x / diff=control ('ref') cl adjust=Dunnett(or tukey);

run;

distribution | link function | note |
---|---|---|

normal | identity | continuous dependent variable, mean difference |

binomial | log | risk ratio from exponentiation of the parameter estimate |

binomial | logit | odds ratio |

poisson | log | risk ratio from exponentiation of the parameter estimate; used for robust error estimate with repeated subject statement |

Parameters estimated with maximum likelihood methods.

Repeated statement: specifies the covariance structure of multivariate responses and iterative fitting algorithm for GEE model fitting.

- Subject: Responses from different subjects are assumed to be statistically independent, and responses within subjects are assumed to be correlated. Variables used in defining the
*subject-effect*must be listed in the CLASS statement. The input data set does not need to be sorted by subject. - Corr= specifies the correlation structure: Un unstructured; IND independent.