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

Support for treatment strategies with interventions at non-consecutiv… #292

Merged
merged 18 commits into from
Oct 11, 2024

Conversation

jmafoster1
Copy link
Contributor

@jmafoster1 jmafoster1 commented Sep 18, 2024

Support for treatment strategies with interventions at non-consecutive timesteps. Timesteps without an explicitly specified intervention are treated as "don't care", so anything can happen.

Copy link

github-actions bot commented Sep 18, 2024

🦙 MegaLinter status: ✅ SUCCESS

Descriptor Linter Files Fixed Errors Elapsed time
✅ PYTHON black 36 0 0.96s
✅ PYTHON pylint 36 0 5.5s

See detailed report in MegaLinter reports

MegaLinter is graciously provided by OX Security

Copy link

codecov bot commented Sep 18, 2024

Codecov Report

Attention: Patch coverage is 98.79518% with 1 line in your changes missing coverage. Please review.

Project coverage is 96.97%. Comparing base (ed832da) to head (e6d46cd).
Report is 20 commits behind head on main.

Files with missing lines Patch % Lines
causal_testing/estimation/ipcw_estimator.py 98.76% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #292      +/-   ##
==========================================
- Coverage   97.07%   96.97%   -0.10%     
==========================================
  Files          30       29       -1     
  Lines        1809     1816       +7     
==========================================
+ Hits         1756     1761       +5     
- Misses         53       55       +2     
Files with missing lines Coverage Δ
causal_testing/testing/causal_test_case.py 100.00% <100.00%> (ø)
causal_testing/estimation/ipcw_estimator.py 99.24% <98.76%> (-0.76%) ⬇️

... and 1 file with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d5f0dad...e6d46cd. Read the comment docs.

@jmafoster1 jmafoster1 requested a review from f-allian September 18, 2024 12:56
@jmafoster1 jmafoster1 marked this pull request as ready for review September 18, 2024 12:56
@jmafoster1
Copy link
Contributor Author

@f-allian, is the codecov just failing on this because the codebase has got slightly bigger? It says I have 100% coverage of the patch, so that's all I can think of, but adding in extra code with 100% coverage should be fine right?

Copy link
Contributor

@f-allian f-allian Sep 19, 2024

Choose a reason for hiding this comment

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

@f-allian, is the codecov just failing on this because the codebase has got slightly bigger? It says I have 100% coverage of the patch, so that's all I can think of, but adding in extra code with 100% coverage should be fine right?

@jmafoster1 Looks like the coverage is failing because you've deleted causal_testing/specification/capabilities.py. Do you know if this was intentional? If so, recommitting it should fix it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, this was intentional. It is no longer required as the new functionality requires timesteps to be specified explicitly, which is what I wrote capabilities.py to handle implicitly.

Copy link
Contributor

@f-allian f-allian left a comment

Choose a reason for hiding this comment

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

@jmafoster1 Feel free to merge following our meeting today :)

@jmafoster1
Copy link
Contributor Author

Thanks. I'm just trying to iron out a couple of bugs, so I'll push that up and then merge in

@jmafoster1 jmafoster1 marked this pull request as draft October 1, 2024 13:47
@jmafoster1 jmafoster1 marked this pull request as ready for review October 7, 2024 09:43
@jmafoster1 jmafoster1 requested a review from f-allian October 7, 2024 09:44
@jmafoster1
Copy link
Contributor Author

Pretty sure I've fixed all the bugs in this. @f-allian , I've re-requested a review as I've changed quite a lot of stuff. Most of it is quite technical, but please let me know if anything seems odd.

Copy link
Contributor

@f-allian f-allian left a comment

Choose a reason for hiding this comment

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

@jmafoster1 The new changes all look good to me

@jmafoster1 jmafoster1 merged commit de0a676 into main Oct 11, 2024
15 of 16 checks passed
@jmafoster1 jmafoster1 deleted the sparse-treatment-strategies branch October 11, 2024 14:31
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