Skip to content

Conversation

@MarIniOnz
Copy link
Contributor

The RHGIOP needs a t-test estimator to work. It is implemented here with its corresponding tests.

@MarIniOnz MarIniOnz requested review from a team and JabobKrauskopf as code owners July 16, 2025 09:42
@MarIniOnz MarIniOnz linked an issue Jul 16, 2025 that may be closed by this pull request
@github-actions
Copy link

Thank you for your pull request! 🎉

Please make sure to read the pull request guidelines at: https://www.medmodels.de/docs/latest/developer_guide/pull-request.html

While you're waiting for a review, please ensure that:

  • All required checks have passed.
  • Documentation is updated if necessary.

@github-actions
Copy link

☂️ Python Coverage

current status: ✅

Overall Coverage

Lines Covered Coverage Threshold Status
5810 5810 100% 100% 🟢

New Files

No new covered files...

Modified Files

File Coverage Status
medmodels/treatment_effect/continuous_estimators.py 100% 🟢
medmodels/treatment_effect/estimate.py 100% 🟢
TOTAL 100% 🟢

updated for commit: 405fe53 by action🐍

@JabobKrauskopf JabobKrauskopf requested review from Copilot and removed request for LauraBoenchenLB July 18, 2025 11:30
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds a t-test estimator implementation to support the RHGIOP functionality. The t-test compares means between treatment and control groups to determine statistical significance.

  • Implements t-test function with configurable equal variance assumption
  • Adds comprehensive test coverage for the new estimator
  • Integrates t-test into the existing continuous estimators framework

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
medmodels/treatment_effect/continuous_estimators.py Implements the core t-test function with EqualVariance enum and adds it to the estimator registry
medmodels/treatment_effect/estimate.py Adds t-test method to the estimate class interface
tests/treatment_effect/test_continuous_estimators.py Comprehensive test cases including valid scenarios and error handling
tests/treatment_effect/test_estimate.py Integration test for t-test estimator

medrecord,
node_index,
outcome_group,
time_attribute="time",
Copy link

Copilot AI Jul 18, 2025

Choose a reason for hiding this comment

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

The time_attribute parameter is hardcoded to "time" instead of using the function parameter. This should be time_attribute=time_attribute to maintain consistency with the treated_outcomes section above.

Suggested change
time_attribute="time",
time_attribute=time_attribute,

Copilot uses AI. Check for mistakes.
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.

Adding t-test to TreatmentEffect estimators

2 participants