Pandas Series: str.title() function
Series-str.title() function
The str.title() function is used to convert strings in the Series/Index to titlecase.
The function is equivalent to str.title().
Syntax:
Series.str.title(self)
Returns: Series/Index of objects
Example:
Python-Pandas Code:
Output:
0 long 1 CAPTAIN 2 this is a car 3 FoOtBaLl dtype: object
Python-Pandas Code:
Output:
0 Long 1 Captain 2 This Is A Car 3 Football dtype: object
Previous: Series-str.swapcase() function
Next: Series-str.upper() function
- Weekly Trends and Language Statistics
- Weekly Trends and Language Statistics