polars.Series.clone#

Series.clone() Self[source]#

Very cheap deepcopy/clone.

See also

clear

Create an empty copy of the current Series, with identical schema but no data.

Examples

>>> s = pl.Series("a", [1, 2, 3])
>>> s.clone()
shape: (3,)
Series: 'a' [i64]
[
        1
        2
        3
]