pyspark.sql.functions.
rtrim
Trim the spaces from right end for the specified string value.
New in version 1.5.