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

indexing with [, drop = TRUE] fails #14

Closed
khusmann opened this issue Sep 30, 2024 · 0 comments · Fixed by #15
Closed

indexing with [, drop = TRUE] fails #14

khusmann opened this issue Sep 30, 2024 · 0 comments · Fixed by #15

Comments

@khusmann
Copy link
Owner

khusmann commented Sep 30, 2024

library(tidyverse)
library(interlacer)

b <- interlaced(c(1,-99,3), na=-99)
b[, drop=TRUE]
#> Error in `b[, drop = TRUE]`:
#> ! Can't index interlaced vectors on dimensions greater than 1.
#> Run `rlang::last_trace()` to see where the error occurred.

Created on 2024-09-30 with reprex v2.0.2

Fix: Add drop argument on [ operator:

`[.interlacer_interlaced` <-  function(x, i, ..., drop) {
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