padding {cwhstring} | R Documentation |
padding
Pads a string.
padding(str, space, with, to=c("left","right","center"))
str |
String to be padded. |
space |
Resulting length of padded string. |
with |
String to pad with. Will be repeated as often as necessary. |
to |
Mode of padding, one of "left","right","center". |
A string
Christian W. Hoffmann, christian.hoffmann@wsl.ch, http://www.wsl.ch/staff/christian.hoffmann
padding("My string",25,"XoX","center") # [1] "XoXXoXXoMy stringXXoXXoXX"