Hi, I noticed difference() returns a larger length vector than x if length(x) < differences.
This differs from the documented return value: "A numeric vector of the same length as x."
packageVersion("tsibble")
#> [1] '1.1.4'
library(tsibble)
#>
#> Attaching package: 'tsibble'
#> The following objects are masked from 'package:base':
#>
#> intersect, setdiff, union
difference(1, differences = 3)
#> [1] NA NA NA
Hi, I noticed
difference()
returns a larger length vector thanx
iflength(x) < differences
. This differs from the documented return value: "A numeric vector of the same length as x."Created on 2024-05-12 with reprex v2.1.0