CreateCountFragment: Create a fragment based on the count of values in a vector...

Description Usage Arguments Examples

View source: R/fragment_count.R

Description

Return a statment summarising the number of items in a set

Usage

1
CreateCountFragment(x, units, fallback)

Arguments

x

A vector of integer values.

units

A vector of length 2 indicating the singular and plural of x's units (e.g., c("country","countries")).

fallback

The character string to return in case of error

Examples

1
CreateCountFragment(as.integer(c(1, 2, 3, NA)), units = c('letter', 'letters'), fallback = "an unknown number of")

polymathematic/Longform documentation built on Jan. 16, 2020, 10:12 p.m.