| wrap {huxtable} | R Documentation |
Functions to get or set the text wrapping property of huxtable table cells.
wrap(ht) wrap(ht) <- value set_wrap(ht, row, col, value, byrow = FALSE)
ht |
A huxtable. |
value |
A logical vector or matrix. If |
row |
A row specifier. See |
col |
An optional column specifier. |
byrow |
If |
For wrap, the wrap attribute.
For set_wrap, the ht object.
ht <- huxtable(a = rep('Some long text', 2))
wrap(ht)[1,] <- TRUE
print_html(ht)
ht <- huxtable(a = 1:3, b = 3:1)
ht2 <- set_wrap(ht, TRUE)
wrap(ht2)
ht3 <- set_wrap(ht, 1:2, 1, TRUE)
wrap(ht3)
ht4 <- set_wrap(ht, 1:2, 1:2, c(TRUE, FALSE), byrow = TRUE)
wrap(ht4)
ht5 <- set_wrap(ht, where(ht == 1), TRUE)
wrap(ht5)