🎓 Tidy tools for academics
Install the development version from Github with:
## install devtools if not already
if (!requireNamespace("devtools", quietly = TRUE)) {
install.packages("devtools")
}
## install tidycat from Github
devtools::install_github("mkearney/tidycat")
Load the package (it, of course, plays nicely with tidyverse).
## load tidyverse
library(tidyverse)
## load tidycat
library(tidycat)
polcom %>%
tidy_ttest(pp_ideology ~ follow_trump) %>%
tidy_summary()
#> # A tidy model
#> Model formula : pp_ideology ~ follow_trump
#> Model type : T-test
#> Model pkg::fun : stats::t.test()
#> Model data : 244 (observations)
#> $fit
#> group df mean diff lo.95 hi.05
#> FALSE 76.911 4.185 0.922 0.308 1.536
#> TRUE 76.911 3.263 -0.922 -0.308 -1.536
#>
#> $coef
#> est t p.value stars
#> 0.922 2.992 0.004 **