Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tsibble::difference() result length not matching input length. #310

Open
NicChr opened this issue May 12, 2024 · 0 comments · May be fixed by #311
Open

tsibble::difference() result length not matching input length. #310

NicChr opened this issue May 12, 2024 · 0 comments · May be fixed by #311

Comments

@NicChr
Copy link

NicChr commented May 12, 2024

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

Created on 2024-05-12 with reprex v2.1.0

mitchelloharawild added a commit to mitchelloharawild/tsibble that referenced this issue May 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant