public class GeneralizedLinearModel extends Object implements LinearModel
E(Y) = μ = g-1(Xβ)where E(Y) is the expected value of Y; Xβ is the linear predictor, a linear combination of unknown parameters, β; g is the link function. The R equivalent function is
glm
.Constructor and Description |
---|
GeneralizedLinearModel(GLMProblem problem)
Solves a generalized linear problem using the Iterative Re-weighted Least Squares algorithm.
|
GeneralizedLinearModel(GLMProblem problem,
GLMFitting fitting)
Constructs a
GeneralizedLinearModel instance. |
Modifier and Type | Method and Description |
---|---|
double |
AIC()
Gets the Akaike information criterion (AIC).
|
GLMBeta |
beta()
Gets the GLM coefficients estimator, β^.
|
double |
Ey(Vector x)
Computes the expectation \(E(y(x))\) given an input.
|
GLMResiduals |
residuals()
Gets the residual analysis of this GLM regression.
|
public GeneralizedLinearModel(GLMProblem problem, GLMFitting fitting)
GeneralizedLinearModel
instance.problem
- the generalized linear regression problem to be solvedfitting
- the fitting method, c.f., GLMFitting
public GeneralizedLinearModel(GLMProblem problem)
problem
- the generalized linear regression problem to be solvedIWLS
public double Ey(Vector x)
LinearModel
Ey
in interface LinearModel
x
- an inputpublic GLMBeta beta()
beta
in interface LinearModel
public GLMResiduals residuals()
residuals
in interface LinearModel
public double AIC()
Copyright © 2010-2020 NM FinTech Ltd.. All Rights Reserved.