bigframes.pandas.api.typing.StringMethods.rstrip#
- StringMethods.rstrip(to_strip: str | None = None) T[source]#
Remove trailing characters.
Strip whitespaces (including newlines) or a set of specified characters from each string in the Series/Index from right side. Replaces any non-strings in Series with NaNs. Equivalent to
str.rstrip().Examples:
>>> import bigframes.pandas as bpd
>>> s = bpd.Series(['Ant', ' Bee ', '\tCat\n', pd.NA]) >>> s.str.rstrip() 0 Ant 1 Bee 2 \tCat 3 <NA> dtype: string
- Parameters:
to_strip (str, default None) – Specifying the set of characters to be removed. All combinations of this set of characters will be stripped. If None then whitespaces are removed.
- Returns:
Series without trailing characters.
- Return type: