Learn R Programming

epikit (version 0.1.6)

fmt_count: Counts and proportions inline

Description

These functions will give proportions for different variables inline.

Usage

fmt_count(x, ...)

Value

a one-element character vector of the format "n (%)"

Arguments

x

a data frame

...

an expression or series of expressions to pass to dplyr::filter()

Examples

Run this code

fmt_count(mtcars, cyl > 3, hp < 100)
fmt_count(iris, Species == "virginica")

Run the code above in your browser using DataLab