Open joshwlambert opened 1 week ago
Good question!
contactmatrix::cm_get_groupings()
returns the "text-format for figure labels etc.".
It may still be helpful to be able to get age groups as vectors. For the example provided in the docs:
this would return
#> $lower
#> [1] 0 5 10 15
#>
#> $higher
#> [1] 5 10 15 20
I can imagine this being particularly helpful if you have uneven age groups. But maybe I'm overthinking this and we don't need this at this time?
Thanks for clarifying.
This might also relate to #10 if {ageutils} has functionality to do this. I've looking through the exported functions from {ageutils} and didn't see any functions that can currently do this, but may have missed it.
I'll tackle this issue and make a PR as I don't think it'll require lots of code. If you're questioning if it's worthwhile you can close the PR without merging.
To check, should the output from the code example above be as follows?
#> $lower
#> [1] 0 5 10 15
#>
#> $higher
#> [1] 4 9 14 19
To check, should the output from the code example above be as follows?
I'm not completely sure. This is one of the things where we probably need to be arbitrary and opinionated. Feel free to go with your favourite option.
In the design principles vignette it states:
Could you please explain what you're after from this point, what would be required that is different from
contactmatrix::cm_get_groupings()
?