modin.pandas.Series.str.len

Series.str.len()[source] (https://github.com/snowflakedb/snowpark-python/blob/v1.26.0/snowpark-python/.tox/docs/lib/python3.9/site-packages/modin/pandas/series_utils.py#L418-L419)

Get the length of a string. For non-string values this returns the length of the string representation.

Returns:

A Series with the length of each value

Return type:

Series

Examples

>>> s = pd.Series(['dog',
...                 '',
...                 5,
...                 {'foo' : 'bar'},
...                 [2, 3, 5, 7],
...                 ('one', 'two', 'three')])
>>> s.str.len()
0    3.0
1    0.0
2    NaN
3    NaN
4    NaN
5    NaN
dtype: float64
Copy
Language: English