Create an empty or n-row null-filled copy of the Series
Description
Returns a n-row null-filled Series with an identical schema.
n
can be greater than the current number of values in the
Series.
Usage
<Series>$clear(n = 0)
Arguments
n
|
Number of (null-filled) rows to return in the cleared frame. |
Value
A n-value null-filled Series with an identical schema
Examples
#> polars Series: shape: (0,)
#> Series: 'a' [i32]
#> [
#> ]
#> polars Series: shape: (5,)
#> Series: 'a' [i32]
#> [
#> null
#> null
#> null
#> null
#> null
#> ]