font_size

0th

Percentile

Font size

Functions to get or set the font size property of huxtable table cells.

Usage
font_size(ht)
font_size(ht) <- value
set_font_size(ht, row, col, value, byrow = FALSE)
Arguments
ht

A huxtable.

value

A numeric vector. This sets the font size in points. Set to NA to reset to the default.

row

A row specifier. See rowspecs for details.

col

An optional column specifier.

byrow

If TRUE, fill in values by row rather than by column.

Value

For font_size, the font_size attribute. For set_font_size, the ht object.

See Also

Other formatting functions: background_color, bold, font, na_string, number_format, text_color

Aliases
  • font_size
  • font_size<-
  • set_font_size
  • font_size.huxtable
  • font_size<-.huxtable
Examples
# NOT RUN {
ht <- huxtable(a = 1:3, b = 1:3)
font_size(ht) <-  14
font_size(ht)


ht <- huxtable(a = 1:3, b = 3:1)
ht2 <- set_font_size(ht, 14)
font_size(ht2)
ht3 <- set_font_size(ht, 1:2, 1, 14)
font_size(ht3)
ht4 <- set_font_size(ht, 1:2, 1:2, c(14, 12), byrow = TRUE)
font_size(ht4)
ht5 <- set_font_size(ht, where(ht == 1), 14)
font_size(ht5)
# }
Documentation reproduced from package huxtable, version 1.2.0, License: MIT + file LICENSE

Community examples

Looks like there are no examples yet.