Learn R Programming

alr3 (version 1.1.12)

sigma.hat: Return the scale estimate for a regression model

Description

This function provides a consistent method to return the estimated scale from a linear, generalized linear, nonlinear, or other model.

Usage

sigma.hat(object)

Arguments

object
A regression object of type lm, glm or nls

Value

  • A nonnegative number

Details

For an lm or nls object, the returned quantity is the square root of the estimate of $\sigma$. For a glm object, the returned quantity is the square root of the estimated dispersion parameter.

Examples

Run this code
data(forbes)
m1 <- lm(Lpres ~ Temp, data=forbes)
sigma.hat(m1)

Run the code above in your browser using DataLab