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

incidence objects will drop groupings with zero days #117

Open
zkamvar opened this issue Jan 23, 2020 · 0 comments
Open

incidence objects will drop groupings with zero days #117

zkamvar opened this issue Jan 23, 2020 · 0 comments
Labels

Comments

@zkamvar
Copy link
Member

zkamvar commented Jan 23, 2020

This makes things difficult for users if they want to acknowledge that there exists a group that they haven't yet sampled.

g <- factor("watermelon", levels = c("watermelon", "cantaloupe"))
i <- incidence::incidence(Sys.Date(), group = g)
incidence::get_counts(i)
#>      watermelon
#> [1,]          1
i
#> <incidence object>
#> [1 cases from days 2020-01-23 to 2020-01-23]
#> [1 groups: watermelon]
#> 
#> $counts: matrix with 1 rows and 1 columns
#> $n: 1 cases in total
#> $dates: 1 dates marking the left-side of bins
#> $interval: 1 day
#> $timespan: 1 days
#> $cumulative: FALSE

Created on 2020-01-23 by the reprex package (v0.3.0)

@zkamvar zkamvar added the bug label Feb 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant