kable_array: Print array using kableExtra

View source: R/kable_array.R

kable_arrayR Documentation

Print array using kableExtra

Description

Print a higher-dimensional array with subheadings for the levels defined by the third and higher dimensions of the array.

Usage

kable_array(a, caption = "", ...)

Arguments

a

array

caption

an optional caption for the printed table

...

functions from kable extra and their arguments

Value

hmtl code to include in a 'asis' chunk

Examples

kable_array(Titanic)
kable_array(Titanic, row_spec = list(0, angle = -30), 
  add_header_above =list(c(' '= 1,'Gender'=2,Freq = 1)),
  column_spec(1, bold = T, border_right = T)) 
## Not run:   
kable_array(Titanic, row_spec = list(0, angle = -30), 
  add_header_above =list(c(' '= 1,'Gender'=2,Freq = 1)),
  column_spec(1, bold = T, border_right = T)) %>%
  save_kable(file = 'test.html', self_contained = T)

## End(Not run)

gmonette/spida2 documentation built on June 12, 2025, 9:44 p.m.