format_col {colorDF}R 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


[Package colorDF version 0.1.4 Index]