Skip to content
Prev 18362 / 20628 Next

nAGQ > 1 in lme4::glmer gives unexpected likelihood

Having said that, I do see that the fits in the MixedModels package for
Julia produce similar values of the deviance with the Laplace approximation
and nAGQ = 7

julia> m1 = fit(MixedModel, @formula(y ~ 1 + (1|group)), dd, Poisson())
Generalized Linear Mixed Model fit by maximum likelihood (nAGQ = 1)
  y ~ 1 + (1 | group)
  Distribution: Poisson{Float64}
  Link: LogLink()

  Deviance: 193.5587

Variance components:
         Column    Variance  Std.Dev.
group (Intercept)  3.9577026 1.9893975

 Number of obs: 100; levels of grouping factors: 10

Fixed-effects parameters:
??????????????????????????????????????????????????
             Estimate  Std.Error  z value  P(>|z|)
??????????????????????????????????????????????????
(Intercept)   2.65175   0.632317     4.19    <1e-4
??????????????????????????????????????????????????

julia> m1 = fit(MixedModel, @formula(y ~ 1 + (1|group)), dd, Poisson(),
nAGQ=7)
Generalized Linear Mixed Model fit by maximum likelihood (nAGQ = 7)
  y ~ 1 + (1 | group)
  Distribution: Poisson{Float64}
  Link: LogLink()

  Deviance: 193.5104

Variance components:
         Column    Variance  Std.Dev.
group (Intercept)  3.9577026 1.9893975

 Number of obs: 100; levels of grouping factors: 10

Fixed-effects parameters:
??????????????????????????????????????????????????
             Estimate  Std.Error  z value  P(>|z|)
??????????????????????????????????????????????????
(Intercept)   2.65175   0.632317     4.19    <1e-4
??????????????????????????????????????????????????

As the person who wrote the first version of the nAGQ code in R I would not
be surprised if there was a constant dropped somewhere.  It is difficult
code.

And the results here in the Julia package make me uncomfortable because the
values of the parameter estimates are identical in the two fits.  I would
expect them to be close but not identical.

Isn't it good to know that there is still room for research in this area?
:-)
On Fri, Apr 24, 2020 at 9:05 AM Douglas Bates <bates at stat.wisc.edu> wrote:

            

  
  
Message-ID: <CAO7JsnTNuNDFMZhJjEq=rRFT8Mj5rXFes3KKOyzFi_Wg7kF=8Q@mail.gmail.com>
In-Reply-To: <31308_1587737137_0Q9A00BAKPTDVU20_CAO7JsnR_TDHYtQDAWOzCp9CBWw7CJ+UfsZk2iTzDWqyQz=dsFw@mail.gmail.com>