# NOT RUN {
# feel free to ignore the following line<U+2014>it allows {broom} to supply
# examples without requiring the model-supplying package to be installed.
if (requireNamespace("speedglm", quietly = TRUE)) {
# load libraries for models and data
library(speedglm)
# generate data
clotting <- data.frame(
u = c(5, 10, 15, 20, 30, 40, 60, 80, 100),
lot1 = c(118, 58, 42, 35, 27, 25, 21, 19, 18)
)
# fit model
fit <- speedglm(lot1 ~ log(u), data = clotting, family = Gamma(log))
# summarize model fit with tidiers
tidy(fit)
glance(fit)
}
# }
Run the code above in your browser using DataLab