categoric_dists: Visualise distributions of categorical columns in a dataframe

Description Usage Arguments

View source: R/vis-categoric-dists.R

Description

Returns a facetted plot of the count and percent of the top levels in each categorical column of a dataframe

Usage

1
2
3
4
5
6
7
categoric_dists(
  x,
  cols = dplyr::everything(),
  top_n = 5,
  na_colour = "blue",
  other_colour = "grey50"
)

Arguments

x

A dataframe containing character columns

cols

Tidyselect columns to use (default = dplyr::everything())

top_n

The top n levels to show - all other values will be lumped into 'Other'

na_colour

Colour for NA bars

other_colour

Colour for lumped 'Other' bars


cj-holmes/holmesr documentation built on Sept. 20, 2020, 12:44 a.m.