View source: R/regression_models.R
Gaussian regression with a log-link | R Documentation |
Gaussian regression with a log-link.
normlog.reg(y, x, tol = 1e-07, maxiters = 100)
y |
The dependent variable, a numerical variable with non negative numbers. |
x |
A matrix or data.frame with the indendent variables. |
tol |
The tolerance value to terminate the Newton-Raphson algorithm. |
maxiters |
The maximum number of iterations that can take place in the regression. |
A Gaussian regression with a log-link is fitted.
A list including:
i |
The number of iterations required by the Newton-Raphson |
loglik |
The log-likelihood value. |
deviance |
The deviance value. |
be |
The regression coefficients |
Stefanos Fafalios
R implementation and documentation: Stefanos Fafalios <stefanosfafalios@gmail.com>
normlog.regs, score.glms, prop.regs, allbetas
y <- abs( rnorm(100) )
x <- matrix( rnorm(100 * 2), ncol = 2)
a <- normlog.reg(y, x)
b <- glm(y ~ x, family = gaussian(log) )
summary(b)
a
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.