-
Notifications
You must be signed in to change notification settings - Fork 1
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
736 fix matched pair flag #162
Conversation
df[df[imputation_flag].isin(["fir", "fic", "fimc", "bir", "c"])].index, | ||
"actual_response", | ||
] = None | ||
|
||
df[f"{forward_or_backward}_match_{target}"] = ( | ||
df.groupby([strata, reference]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for future reference fill_group could be used here ( highlighted the wrong rows, i was referring line 60)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Anton, would love to hear more about this - I tried searching "fill_group pandas" but nothing is coming up!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All looking good, just one comment which needs sorting
Pull Request Title
Fix matched pair flag
Summary
This request implements ASAP-736 by fixing the matched pair flag function. Also ran into some issues with the ratio_of_means unit tests as a result of this change, so also needed to fix those issues (primarily fixed by adding in the imputation_flag column that the function needed, fixing a bug in join_manual_constructions where a column was duplicated and dropping some columns from expected outputs).
Type of Change
Checklists
This pull request meets the following requirements:
Creator Checklist
If you feel some of these conditions do not apply for this pull request, please
add a comment to explain why.
Reviewer Checklist
Additional Information
Please provide any additional information or context that would help the reviewer understand the changes in this pull request.
Related Issues
Link any related issues or pull requests here.