Skip to content

Commit

Permalink
Merge branch 'pa/issue792' of github.com:JuliaStats/MixedModels.jl in…
Browse files Browse the repository at this point in the history
…to pa/issue792
  • Loading branch information
palday committed Dec 10, 2024
2 parents b771dbe + dcc441e commit f3a1eb2
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions src/generalizedlinearmixedmodel.jl
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ function GeneralizedLinearMixedModel(
kwargs...,
)
return GeneralizedLinearMixedModel(
f, Tables.columntable(tbl), d, l; kwargs...,
f, Tables.columntable(tbl), d, l; kwargs...
)
end

Expand Down Expand Up @@ -467,15 +467,15 @@ function GeneralizedLinearMixedModel(

# if the response is constant, there's no point (and this may even fail)
constresponse || try
deviance!(res, 1)
catch ex
ex isa PosDefException || rethrow()
@warn "Evaluation at default initial parameter vector failed, " *
"initializing to very small variances. This may result in long " *
"model fitting times. You will probably also need to use " *
"`init_from_lmm=[:β, :θ]` in order to fit the model."
res.optsum.initial[res.optsum.initial .!= 0] .= 1e-8
end
deviance!(res, 1)
catch ex
ex isa PosDefException || rethrow()
@warn "Evaluation at default initial parameter vector failed, " *
"initializing to very small variances. This may result in long " *
"model fitting times. You will probably also need to use " *
"`init_from_lmm=[:β, :θ]` in order to fit the model."
res.optsum.initial[res.optsum.initial .!= 0] .= 1e-8
end

return res
end
Expand Down

0 comments on commit f3a1eb2

Please sign in to comment.