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

Add create_cutting_test() and multitest() #215

Merged
merged 4 commits into from
Mar 11, 2024

Conversation

jdblischak
Copy link
Collaborator

This PR introduces a new function create_cutting_test(). Similar to create_cutting(), it is a function factory that generates functions that can easily be passed around. This enables us to do various new things.

  1. I created a new function multitest(). It allows running multiple tests at once on a cut data set. It currently returns a list because the test functions do not return consistent outputs
  2. I updated the sim_gs_n() argument test to accept a list of test functions, one per cutting. This is mostly a proof of concept at the moment. More work will be required before we can support allowing multiple tests per cutting and mixing heterogenous tests (as it is currently written sim_gs_n() requires all the test results to be combined into a single output data frame)

I also took the time to clean up some of the roxygen2 docs since I was the one who introduced a lot of the macros.

Lastly, I didn't touch maxcombo() in this PR, but you can imagine that we could also use create_cutting_test() to be able to pass any arbitrary number of test functions to maxcombo(). But just like for sim_gs_n() and multitest(), this would be facilitated by the test functions having consistent output.

@jdblischak jdblischak self-assigned this Mar 7, 2024
@jdblischak jdblischak changed the title Add create_cutting_test() Add create_cutting_test() and multitest() Mar 7, 2024
@jdblischak jdblischak force-pushed the create-cutting-test branch from 61f38f5 to f96a370 Compare March 8, 2024 19:23
@jdblischak
Copy link
Collaborator Author

Rebased onto 9ac40f3 to include #214

Copy link
Collaborator

@nanxstats nanxstats left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@nanxstats nanxstats merged commit db0d586 into Merck:main Mar 11, 2024
7 checks passed
@jdblischak jdblischak deleted the create-cutting-test branch March 20, 2024 18:15
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

Successfully merging this pull request may close these issues.

2 participants