graph_group_rare_values: Graph effect of dropping "rare" values from a vector of data

Description Usage Arguments Value Examples

View source: R/graphs.R

Description

Makes a graph showing what either the number of unique values or the percent of values are dropped when excluding values that are less common than k% of the data for every value of k from 1%-100%.

Usage

1
graph_group_rare_values(data, percent_dropped = FALSE)

Arguments

data

A vector of strings or numbers.

percent_dropped

If FALSE (default), will show the number of unique values in the data after excluding values that are rarer than k% (from 1-99%). Else, will show the percent of the data dropped after excluding values that are rarer than k% (from 1-99%)

Value

A ggplot2 graph

Examples

1
2
graph_group_rare_values(deidentify::initiations$offense_category)
graph_group_rare_values(deidentify::initiations$offense_category, percent_dropped = TRUE)

phillydao/deidentify documentation built on Feb. 4, 2021, 2:31 p.m.