Glance accepts a model object and returns a tibble::tibble() with exactly one row of model summaries. The summaries are typically goodness of fit measures, p-values for hypothesis tests on residuals, or model convergence information.

Glance never returns information from the original call to the modelling function. This includes the name of the modelling function or any arguments passed to the modelling function.

Glance does not calculate summary measures. Rather, it farms out these computations to appropriate methods and gathers the results together. Sometimes a goodness of fit measure will be undefined. In these cases the measure will be reported as NA.

# S3 method for rlm
glance(x, ...)

Arguments

x

An rlm object returned by MASS::rlm().

...

Additional arguments. Not used. Needed to match generic signature only. Cautionary note: Misspelled arguments will be absorbed in ..., where they will be ignored. If the misspelled argument has a default value, the default value will be used. For example, if you pass conf.lvel = 0.9, all computation will proceed using conf.level = 0.95. Additionally, if you pass newdata = my_tibble to an augment() method that does not accept a newdata argument, it will use the default value for the data argument.

Value

A one-row tibble::tibble with columns:

sigma

The square root of the estimated residual variance

converged

whether the IWLS converged

logLik

the data's log-likelihood under the model

AIC

the Akaike Information Criterion

BIC

the Bayesian Information Criterion

deviance

deviance

Details

For tidiers for models from the robust package see tidy.lmRob() and tidy.glmRob().

See also

Examples

library(MASS) r <- rlm(stack.loss ~ ., stackloss) tidy(r)
#> # A tibble: 4 x 4 #> term estimate std.error statistic #> <chr> <dbl> <dbl> <dbl> #> 1 (Intercept) -41.0 9.81 -4.18 #> 2 Air.Flow 0.829 0.111 7.46 #> 3 Water.Temp 0.926 0.303 3.05 #> 4 Acid.Conc. -0.128 0.129 -0.992
#> # A tibble: 21 x 9 #> stack.loss Air.Flow Water.Temp Acid.Conc. .fitted .se.fit .resid .hat #> * <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> #> 1 42 80 27 89 38.9 1.34 3.05 0.327 #> 2 37 80 27 88 39.1 1.38 -2.08 0.343 #> 3 37 75 25 90 32.8 1.02 4.18 0.155 #> 4 28 62 24 87 21.5 0.875 6.50 0.0713 #> 5 18 62 22 87 19.6 0.558 -1.65 0.0562 #> 6 18 62 23 87 20.6 0.679 -2.57 0.0835 #> 7 19 62 24 93 20.7 1.14 -1.73 0.230 #> 8 20 62 24 93 20.7 1.14 -0.731 0.230 #> 9 15 58 23 87 17.3 0.914 -2.25 0.155 #> 10 14 58 18 80 13.5 1.09 0.481 0.213 #> # ... with 11 more rows, and 1 more variable: .sigma <dbl>
#> # A tibble: 1 x 6 #> sigma converged logLik AIC BIC deviance #> <dbl> <lgl> <dbl> <dbl> <dbl> <dbl> #> 1 2.44 TRUE -53.0 116. 121. 191.