maxframe.dataframe.Series.str.rjust#
- Series.str.rjust(width: int, fillchar: str = ' ')#
Pad left side of strings in the Series/Index.
Equivalent to
str.rjust().- Parameters:
- Returns:
A Series or Index where the strings are modified by
str.rjust().- Return type:
Series/Index of objects.
See also
Series.str.rjustFills the left side of strings with an arbitrary character.
Series.str.ljustFills the right side of strings with an arbitrary character.
Series.str.centerFills both sides of strings with an arbitrary character.
Series.str.zfillPad strings in the Series/Index by prepending ‘0’ character.
Examples
For Series.str.center:
>>> import maxframe.dataframe as md >>> ser = md.Series(["dog", "bird", "mouse"]) >>> ser.str.center(8, fillchar=".").execute() 0 ..dog... 1 ..bird.. 2 .mouse.. dtype: str
For Series.str.ljust:
>>> ser = md.Series(["dog", "bird", "mouse"]) >>> ser.str.ljust(8, fillchar=".").execute() 0 dog..... 1 bird.... 2 mouse... dtype: str
For Series.str.rjust:
>>> ser = md.Series(["dog", "bird", "mouse"]) >>> ser.str.rjust(8, fillchar=".").execute() 0 .....dog 1 ....bird 2 ...mouse dtype: str