knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>",
  fig.path = "README-"
)

descriptr

Generate descriptive statistics

CRAN_Status_Badge cran checks r-universe R build status Lifecycle: stable Coverage status status

Installation

# Install release version from CRAN
install.packages("descriptr")

# Install development version from GitHub
# install.packages("devtools")
devtools::install_github("rsquaredacademy/descriptr")

# Install the development version from `rsquaredacademy` universe
install.packages("descriptr", repos = "https://rsquaredacademy.r-universe.dev")

Articles

Usage

We will use a modified version of the mtcars data set in the below examples. The only difference between the data sets is related to the variable types.

library(descriptr)
str(mtcarz)

Continuous Data

Summary Statistics

ds_summary_stats(mtcarz, mpg)

Frequency Distribution

ds_freq_table(mtcarz, mpg)

Categorical Data

One Way Table

ds_freq_table(mtcarz, cyl)

Two Way Table

ds_cross_table(mtcarz, cyl, gear)

Group Summary

ds_group_summary(mtcarz, cyl, mpg)

Multiple Variable Statistics

ds_tidy_stats(mtcarz, mpg, disp, hp)

Features

Getting Help

If you encounter a bug, please file a minimal reproducible example using reprex on github. For questions and clarifications, use StackOverflow.



rsquaredacademy/descriptr documentation built on July 9, 2021, 8:13 p.m.