Skip to contents

Creates an svg object based on the direction of change of a performance variable. The svg code can be embedded in a data frame and passed to gt() for prettifying a table. Appears to work well when applied with purrr::map()

Usage

make_chg_shape(change_dir)

Arguments

change_dir

variable indicating direction of change or not applicable

Value

gt html() code for an svg

See also

Other MDB helper functions: calc_growth(), format_indicator(), label_aggregation(), make_achv_shape()

Examples

if (FALSE) {
 rank_chg("increase") %>% htmltools::html_print()
 rank_chg("decrease") %>% htmltools::html_print()
 df %>% mutate(chg_dir = purrr::map(present_z_direction, rank_chg))
 }