align {pillar} | R Documentation |
Alignment helper
Description
Facilitates easy alignment of strings within a character vector. Designed to help implementers of formatters for custom data types.
Usage
align(x, width = NULL, align = c("left", "right"), space = " ")
Arguments
x |
A character vector |
width |
The width that each string is padded to. If |
align |
How should strings be aligned? If |
space |
What character should be used for the padding? |
Examples
align(c("abc", "de"), align = "left")
align(c("abc", "de"), align = "right")
[Package pillar version 1.9.0 Index]