powered by
strs_ljust left-justifies each element of a character vector in a field of a specified width. It is similar to Python's str.ljust() method.
strs_ljust
str.ljust()
strs_ljust(string, width, fillchar = " ")
A character vector of the same length as string, with each element left-justified in a field of the specified width.
string
A character vector where each element is a string to be left-justified.
The total width of the field in which the string is to be left-justified.
A character used for padding on the right.
Python str.ljust() documentation
strs_ljust("hello", 10) strs_ljust("world", 10, "*")
Run the code above in your browser using DataLab