Skip to content
Prev 8323 / 20628 Next

Testing out glmmADMB

[cc'd to r-sig-mixed-models; I'm taking the liberty of cc'ing this so
that the discussion can be browsed by others]
On 12-05-30 06:45 PM, Mueller,John Martin wrote:
It means there was *some* kind of problem, ranging from hitting
maximum iterations to a non-positive-definite variance-covariance matrix
for the estimated parameters.  You can try setting verbose=TRUE and
looking near the bottom of the voluminous output to see if you can get
something more useful out of it. glmmADMB could use a lot of improvement
in the way it reports problems (as could the underlying AD Model Builder
code).  The thing you have to keep in mind when fitting complex models
is that there are a lot of things that can go wrong (probably you
already know that ...)
The first place to look is ?admbControl , but that only you gives a
couple of options for tweaking.  The next thing I would try to do is to
create plots of your data that are as subdivided as possible (I use
ggplot a lot for this) and try to identify whether there are odd data
points, or odd groups, that could be messing things up.  Depending on
how much time and effort you have available, I would also considering
simulating models with similar structure to your data and see whether
you can fit them successfully (and get reasonable answers); if not (i.e.
if it fails when the data is *known* to be structured in exactly the
same way as the model assumes), then your model is probably just too
complicated to handle.

  Another option is trying better starting values, and in particular
getting reasonable starting values by building up from a simpler model.
 The usual tricks of centering and scaling continuous predictors, and
orthogonalizing or otherwise dealing with strongly correlated
predictors, are also useful (although if you're only dealing with a
single continuous predictor ranging from 0 to 5 that may not matter that
much).
I assume you are trying to fit a (log-)linear model to TIME.  I think
that something like ~ TIME + (TIME|LOCATION/ID) would be what you
wanted; this would fit an overall slope (and intercept: the "1+" in the
fixed-effect part of the formula is optional/implicit); variation in the
slope with respect to time across locations; and variation in the slope
with respect to time across firms within location.