Dear R-helpers,
I'd like to use glmmPQL to predict binary responses based on a data.frame
data1
containing N entries (N<1000):
target covariate1 covariate2 covariate3 ... covariateM
cluster
134131 1 -0.30031885 0 0 -2.886870e-07
1
38370 1 -0.04883229 0 1 -1.105720e-07
1
19315 1 -0.11084267 0 0 6.362602e-07
1
33806 1 -0.14529289 0 0 -1.361914e-07
1
154332 1 -0.07983748 0 1 -7.635439e-07
1
...
17228 0 -0.49668507 0 1 -2.954118e-07
1
41147 0 -0.32787902 0 1 -1.502238e-06
1
104213 0 0.17164908 0 0 -2.119738e-06
1
28071 0 -2.08828495 0 0 -7.640990e-07
1
91 0 1.47042214 0 0 -5.661632e-07
1
The responses are in column "target", and there are M covariates. All
observations
belong to cluster 1.
The data is to be modelled without fixed effects, i.e., a by a zero-mean
random effects model.
Additionally, the model is to be fed with a correlation structure
(to avoid double entries, a column x<-rnorm(nrow(data1),0,0.000001) is
appended):
correlation=corGaus(form=~covariate1 + covariate2 + ... +covariateM + x,
nugget=FALSE)
The data is visible to glmmPQL:
attach(data1)
Is
glmmPQLm<-glmmPQL(target~0,random=~1|cluster, data=data1,
correlation=corGaus(form=~covariate1 + covariate2 + ... +covariateM + x,
nugget=FALSE),
family="binomial") the right expression to fit the model ?
Thanks,
Don Muang
[[alternative HTML version deleted]]