style_num

0th

Percentile

Styling helpers

Functions that allow implementers of formatters for custom data types to maintain a consistent style with the default data types.

Usage
style_num(x, negative, significant = rep_along(x, TRUE))

style_subtle(x)

style_bold(x)

style_na(x)

style_neg(x)

Arguments
x

The character vector to style.

negative, significant

Logical vector the same length as x that indicate if the values are negative and significant, respectively

Details

style_subtle() is affected by the pillar.subtle option.

style_bold() is affected by the pillar.bold option.

style_neg() is affected by the pillar.neg option.

See Also

pillar-package for a list of options

Aliases
  • style_num
  • style_subtle
  • style_bold
  • style_na
  • style_neg
Examples
# NOT RUN {
style_num(
  c("123", "456"),
  negative = c(TRUE, FALSE)
)
style_num(
  c("123", "456"),
  negative = c(TRUE, FALSE),
  significant = c(FALSE, FALSE)
)
style_subtle("text")
style_bold("Petal.Width")
style_na("NA")
style_neg("123")
# }
Documentation reproduced from package pillar, version 1.1.0, License: GPL-3

Community examples

Looks like there are no examples yet.