Skip to content

Commit

Permalink
phrasing
Browse files Browse the repository at this point in the history
Co-authored-by: Alex Arslan <[email protected]>
  • Loading branch information
palday and ararslan authored Aug 21, 2023
1 parent 5c4c3ac commit 2dba1a3
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 7 deletions.
2 changes: 1 addition & 1 deletion ext/EffectsGLMExt.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module EffectsGLMExt
using Effects

using GLM: AbstractGLM, Link, Link01, inverselink
using StatsModels: TableRegressionModel
using Effects.StatsModels: TableRegressionModel

# TODO: upstream a Link(::TableRegressionModel{<:AbstractGLM})
Effects._model_link(m::TableRegressionModel{<:AbstractGLM}, ::AutoInvLink) = Link(m.model)
Expand Down
18 changes: 12 additions & 6 deletions src/regressionmodel.jl
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,14 @@
Singleton type indicating that the inverse link should be automatically
determined from the model type.
This will only work for model types with an appropriate extension on
Julia 1.9+. If an appropriate extension is not defined, then an error
will occur.
!!! compat "Julia 1.9"
Automatic inverse link determination is implemented using package
extensions, which are available beginning in Julia 1.9.
An error is thrown if the inverse link cannot be determined. This will
always occur with Julia versions prior to 1.9, and will otherwise occur
when no extension has been loaded that specifies the link function for
the model type.
Currently, this is only implemented for GLM.jl and MixedModels.jl
"""
Expand Down Expand Up @@ -71,9 +76,10 @@ Pointwise standard errors are written into the column specified by `err_col`.
automatic differentiation. This means that the `invlink` function must be
differentiable and should not involve inplace operations.
The special singleton value `AutoInvLink()` can be used to specify that
the appropriate inverse link should be determined and, where possible, a
direct or analytic computation of the derivative is used.
On Julia versions 1.9 or later, the special singleton value `AutoInvLink()`
can be used to specify that the appropriate inverse link should be determined
automatically. In that case, a direct or analytic computation of the derivative
is used when possible.
Effects are computed using the model's variance-covariance matrix, which is
computed by default using `StatsBas.vcov`. Alternative methods such as the
Expand Down

0 comments on commit 2dba1a3

Please sign in to comment.