format_col: Format a vector using styles

View source: R/styles.R

format_colR Documentation

Format a vector using styles

Description

Format a vector (data frame column) aligning, rounding the numbers and adding color.

Usage

format_col(
  x,
  col_name = NULL,
  style = NULL,
  df_style = NULL,
  format = TRUE,
  col_width = NULL,
  prefix = " ",
  min.width = 5L,
  max.width = NULL
)

Arguments

x

a vector

col_name

optional: a column name (see Details)

style

A list with style definition

df_style

style for the whole data frame

format

Whether the vector should be formatted and aligned

col_width

optional: width to which elements of the vector should be aligned

prefix

prefix (column separator) to add to each element of x

min.width

minimum width of a column

max.width

maximum width of a column


colorDF documentation built on Sept. 26, 2022, 5:06 p.m.