strs_rjust | R Documentation |
strs_rjust
right-justifies each element of a character vector in a field of
a specified width. It is similar to Python's str.rjust()
method.
strs_rjust(string, width, fillchar = " ")
string |
A character vector where each element is a string to be right-justified. |
width |
The total width of the field in which the string is to be right-justified. |
fillchar |
A character used for padding on the left. |
A character vector of the same length as string
, with each element
right-justified in a field of the specified width.
Python str.rjust() documentation
strs_rjust("hello", 10)
strs_rjust("world", 10, "*")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.