Debian Codegraph @

man/tidy.lm.beta.Rd

raw
1 % Generated by roxygen2: do not edit by hand
2 % Please edit documentation in R/lm-beta.R
3 \name{tidy.lm.beta}
4 \alias{tidy.lm.beta}
5 \title{Tidy a(n) lm.beta object}
6 \usage{
7 \method{tidy}{lm.beta}(x, conf.int = FALSE, conf.level = 0.95, ...)
8 }
9 \arguments{
10 \item{x}{An \code{lm.beta} object created by \link[lm.beta:lm.beta]{lm.beta::lm.beta}.}
11
12 \item{conf.int}{Logical indicating whether or not to include a confidence
13 interval in the tidied output. Defaults to \code{FALSE}.}
14
15 \item{conf.level}{The confidence level to use for the confidence interval
16 if \code{conf.int = TRUE}. Must be strictly greater than 0 and less than 1.
17 Defaults to 0.95, which corresponds to a 95 percent confidence interval.}
18
19 \item{...}{Additional arguments. Not used. Needed to match generic
20 signature only. \strong{Cautionary note:} Misspelled arguments will be
21 absorbed in \code{...}, where they will be ignored. If the misspelled
22 argument has a default value, the default value will be used.
23 For example, if you pass \code{conf.lvel = 0.9}, all computation will
24 proceed using \code{conf.level = 0.95}. Two exceptions here are:
25 \itemize{
26 \item \code{tidy()} methods will warn when supplied an \code{exponentiate} argument if
27 it will be ignored.
28 \item \code{augment()} methods will warn when supplied a \code{newdata} argument if it
29 will be ignored.
30 }}
31 }
32 \description{
33 Tidy summarizes information about the components of a model.
34 A model component might be a single term in a regression, a single
35 hypothesis, a cluster, or a class. Exactly what tidy considers to be a
36 model component varies across models but is usually self-evident.
37 If a model has several distinct types of components, you will need to
38 specify which components to return.
39 }
40 \details{
41 If the linear model is an \code{mlm} object (multiple linear model),
42 there is an additional column \code{response}.
43
44 If you have missing values in your model data, you may need to refit
45 the model with \code{na.action = na.exclude}.
46 }
47 \examples{
48 \dontshow{if (rlang::is_installed("lm.beta")) withAutoprint(\{ # examplesIf}
49
50 # load libraries for models and data
51 library(lm.beta)
52
53 # fit models
54 mod <- stats::lm(speed ~ ., data = cars)
55 std <- lm.beta(mod)
56
57 # summarize model fit with tidiers
58 tidy(std, conf.int = TRUE)
59
60 # generate data
61 ctl <- c(4.17, 5.58, 5.18, 6.11, 4.50, 4.61, 5.17, 4.53, 5.33, 5.14)
62 trt <- c(4.81, 4.17, 4.41, 3.59, 5.87, 3.83, 6.03, 4.89, 4.32, 4.69)
63 group <- gl(2, 10, 20, labels = c("Ctl", "Trt"))
64 weight <- c(ctl, trt)
65
66 # fit models
67 mod2 <- lm(weight ~ group)
68 std2 <- lm.beta(mod2)
69
70 # summarize model fit with tidiers
71 tidy(std2, conf.int = TRUE)
72 \dontshow{\}) # examplesIf}
73 }
74 \seealso{
75 Other lm tidiers:
76 \code{\link{augment.glm}()},
77 \code{\link{augment.lm}()},
78 \code{\link{glance.glm}()},
79 \code{\link{glance.lm}()},
80 \code{\link{glance.summary.lm}()},
81 \code{\link{glance.svyglm}()},
82 \code{\link{tidy.glm}()},
83 \code{\link{tidy.lm}()},
84 \code{\link{tidy.mlm}()},
85 \code{\link{tidy.summary.lm}()}
86 }
87 \concept{lm tidiers}
88 \value{
89 A \code{\link[tibble:tibble]{tibble::tibble()}} with columns:
90 \item{conf.high}{Upper bound on the confidence interval for the estimate.}
91 \item{conf.low}{Lower bound on the confidence interval for the estimate.}
92 \item{estimate}{The estimated value of the regression term.}
93 \item{p.value}{The two-sided p-value associated with the observed statistic.}
94 \item{statistic}{The value of a T-statistic to use in a hypothesis that the regression term is non-zero.}
95 \item{std.error}{The standard error of the regression term.}
96 \item{term}{The name of the regression term.}
97
98 }