Skip to contents

Return a commentary snippet for one or more values. Formats the numbers as a comma separated numeric and provides simple up/down commentary

Usage

number_change(x, description = "up", unchanged_limit = 100, ...)

Arguments

x

a vector of numeric values.

description

code of descriptive words used in commentary. Defaults to "up"; up/down/unchanged.

unchanged_limit

numeric, the value below which you consider the parameter to not represent a change in either direction. Defaults to 100.

...

additional arguments to pass to the scales::comma function

Value

Returns a brief commentary (including the figure for increases or decreases) as a string