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

Neither calculateSumB can handle all cohorts < successionTimeStep #42

Open
ianmseddy opened this issue Sep 13, 2019 · 4 comments
Open

Comments

@ianmseddy
Copy link
Collaborator

sumB will become NA, as the subset returns an empty table

@CeresBarros
Copy link
Member

  1. I don't think this is a "bug", it's a choice to only calculate sumB for the older cohorts, which is why there are several instances in the module were the function is not used and instead we calculate sumB := sum(B) (because we want all the cohorts to be included).
    see e.g. line # 32 in age-cohorts.R and line # 1350 in LBMR.R summaryRegen function

@ianmseddy
Copy link
Collaborator Author

Fair, but that means we should test whether you have at least 1 cohort with age > successionTimestep, to avoid calling it and hitting the error. I think anyway.

@CeresBarros
Copy link
Member

sure, wanna implement :P?

@CeresBarros
Copy link
Member

@ianmseddy is this still an issue?

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

No branches or pull requests

2 participants