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

Elements of an 's_group' should be atomic #32

Open
basille opened this issue Sep 29, 2020 · 0 comments
Open

Elements of an 's_group' should be atomic #32

basille opened this issue Sep 29, 2020 · 0 comments

Comments

@basille
Copy link
Member

basille commented Sep 29, 2020

Simple example from the vignette:

singlegroup <- make_s_group(list(id = "TTP_058", month = 4))
str(singlegroup)

Which works as expected. However, I can also have vectors or lists of length >1 for each variable, e.g.:

singlegroup <- make_s_group(list(id = "TTP_058", month = list(a = 1, b = 2)))
str(singlegroup)

This also works with no error, but defeats the purpose of the individual identification. I think the structure should be stricter and only allow vectors of length 1 (or other things that can be coerced to a vector of length 1).

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

1 participant