[R-sig-ME] mixed mutlinomial regression for count data with, overdisperion & zero-inflation
dave fournier
davef at otter-rsch.com
Fri May 20 05:05:06 CEST 2016
I found a version of glmmadmb for Windows 64bit ( I sadly assume) that
almost does the job out of the
box. Using the information from R Forge
http://glmmadmb.r-forge.r-project.org/
which points to
http://www.admb-project.org/buildbot/glmmadmb/
where I found this exe
glmmadmb-mingw64-r3274-windows10-mingw64.exe
Using your glmmadmb.pin and glmmadmb.dat files (which you renamed to
glmmadmb1.pin and glmmadmb1.dat) I ran the following script.
./glmmadmb-mingw64-r3274-windows10-mingw64.exe -crit 1.e-6 -ind
glmmadmb1.dat -ainp glmmadmb.par -maxph 5 -shess -noinit -phase 7
(I have added two extra phases and modified the convergence criterion to
1.e-6.)
which converged with nice estimates etc. Now one of the really nice
things about actually fitting the model
rather than resorting to other diagnostics is that if you are successful
you can look at the fit. In this
case the squared residuals divided by the predicted variance. These are
in the output glmmadmb.rep file.
I sorted them in R and looked at the large ones at the end.
index obs pred whatever its called
1206 1206 319 3.47536e+01 1.24498e+01
305 305 4490 2.18655e+03 1.29949e+01
1074 1074 413 5.13552e+01 1.36380e+01
1385 1385 4002 1.68879e+03 1.69679e+01
854 854 224 1.22219e+01 1.96515e+01
1691 1691 2713 8.33316e+02 2.27056e+01
1427 1427 1732 3.92621e+02 2.44684e+01
1433 1433 1612 3.25266e+02 2.72590e+01
1313 1313 1815 3.52356e+02 3.25137e+01
341 341 2031 3.55824e+02 4.22336e+01
191 191 5814 7.18097e+02 1.93656e+02
599 599 3586 2.68911e+02 2.19118e+02
So you have a few gigantic outliers. This is fairly common with data
for which the model
has problems converging. But rather than celebrating the failure of the
model as a useful diagnostic for
bad data it is really useful to coax it to fit the data and investigate
the residuals,
If you can explain them it should help.
More information about the R-sig-mixed-models
mailing list