huxtable (version 0.2.1)

print_screen: Print a huxtable on screen

Description

Print a huxtable on screen

Usage

print_screen(ht, ...)

to_screen(ht, ...)

# S3 method for huxtable to_screen(ht, borders = c("both", "horizontal", "vertical", "neither"), blank = NULL, colnames = TRUE, colnames_color = "blue", ...)

Arguments

ht
A huxtable.
...
Passed on to to_screen.
borders
Print 'horizontal' borders, 'vertical' borders, 'both' or 'neither'. May be abbreviated.
blank
Character to print for cell divisions with no border. If NULL, print a space ' ' but don't print empty horizontal borders.
colnames
Whether or not to print colum names.
colnames_color
Color to print column names. Note: this won't work in RStudio.

Value

to_screen returns a string. print_screen prints the string and returns NULL.

Details

Only colspan, rowspan, align and caption properties are shown.

See Also

Other printing functions: print_html, print_latex, print_md

Examples

Run this code
ht <- huxtable(a = 1:5, b = 1:5, add_colnames = TRUE)
ht <- set_all_borders(ht, 1:6, 1:2, 1)
right_border(ht)[,1] <- left_border(ht)[,2] <- 0
align(ht)[1,] <- 'left'
print_screen(ht)
print_screen(ht, blank = '.')
print_screen(ht, borders = 'horiz')

Run the code above in your browser using DataCamp Workspace