freq_tab: freq_tab

Description Usage Arguments Details Value Author(s) Examples

View source: R/utility_functions.r

Description

Generate a tidy n-way frequency table

Usage

1

Arguments

df

tibble or data frame (implicit within pipline)

...

grouping, as with group_by()

Details

tidyverse, pipeline, and dplyr-friendly frequency tables

Value

A tibble with the grouping variables, the N ('n') per group, and the proportion ('prop') of each group, calculated with respect to the outermost grouping variable.

Author(s)

Kieran Healy

Examples

1
2
3
4
## Not run: 
mtcars %>% freq_tab(vs, gear, carb)

## End(Not run)

kjhealy/socviz documentation built on April 22, 2018, 7:13 p.m.