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

Function to generate multiple data definitions of the same type #125

Closed
kgoldfeld opened this issue Dec 29, 2021 · 2 comments
Closed

Function to generate multiple data definitions of the same type #125

kgoldfeld opened this issue Dec 29, 2021 · 2 comments
Assignees
Labels
feature feature request or enhancement

Comments

@kgoldfeld
Copy link
Owner

If I want a definition table that will generate a large number of similar variables (such as g1, ..., g4 below), the only way to currently do this is by calling defData for each instance. If they are truly identical, I'd like to make it possible with a single call.

   varname     formula variance        dist     link
1:      g1 1/3;1/3;1/3        0 categorical identity
2:      g2 1/3;1/3;1/3        0 categorical identity
3:      g3 1/3;1/3;1/3        0 categorical identity
4:      g4 1/3;1/3;1/3        0 categorical identity
5:       a         1;1        0   trtAssign identity
6:       y        0.10        0      binary identity
@kgoldfeld kgoldfeld added the feature feature request or enhancement label Dec 29, 2021
@kgoldfeld kgoldfeld self-assigned this Dec 29, 2021
@kgoldfeld
Copy link
Owner Author

@assignUser I created functions defRepeat and defRepeatAdd in branch def-data-enhancements. I took a look at creating a test, but not entirely clear one would be appropriate here since the functions are largely derivative of defData and defDataAdd, respectively. I couldn't find a unit test for defData or defDataAdd, which I was hoping would serve as a model. If you have a chance, take a quick look, and let me know what you think.

@assignUser
Copy link
Collaborator

#134

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature feature request or enhancement
Projects
None yet
Development

No branches or pull requests

2 participants