width {flextable} | R Documentation |
Set columns width
Description
Defines the widths of one or more columns in the
table. This function will have no effect if you have
used set_table_properties(layout = "autofit")
.
set_table_properties()
can provide an alternative to fixed-width layouts
that is supported with HTML and Word output that can be set
with set_table_properties(layout = "autofit")
.
Usage
width(x, j = NULL, width, unit = "in")
Arguments
x |
a |
j |
columns selection |
width |
width in inches |
unit |
unit for width, one of "in", "cm", "mm". |
Details
Heights are not used when flextable is been rendered into HTML.
See Also
Other flextable dimensions:
autofit()
,
dim.flextable()
,
dim_pretty()
,
fit_to_width()
,
flextable_dim()
,
height()
,
hrule()
,
ncol_keys()
,
nrow_part()
,
set_table_properties()
Examples
ft <- flextable(head(iris))
ft <- width(ft, width = 1.5)
ft
[Package flextable version 0.9.6 Index]