-
Notifications
You must be signed in to change notification settings - Fork 5
Description
causal_testing/testing/causal_test_case.py:12:0: R0902: Too many instance attributes (9/7) (too-many-instance-attributes)
Currently, we have
self.base_test_case = base_test_case
self.control_value = control_value
self.expected_causal_effect = expected_causal_effect
self.outcome_variable = base_test_case.outcome_variable
self.treatment_variable = base_test_case.treatment_variable
self.treatment_value = treatment_value
self.estimate_type = estimate_type
self.effect = base_test_case.effect
self.effect_modifier_configuration = {}
Perhaps we might want to reconsider the purpose of expected_causal_effect
(implemented in CausalTestOutcome') and see if we can rework some aspects of this into there. I think it'd be quite reasonable to have a class to represent "we expect the outcome Y to Increase according to the ATE effect measure". That would cut three variables (
outcome_variable,
estimate_type, and
effect) down to 1. As with
AbstractCausalTestCase, we could also pass the effect modifiers directly into the estimator, as we do with the adjustment set. We should also stop unpacking the data class in the
init` method!
causal_testing/testing/causal_test_case.py:24:4: R0913: Too many arguments (7/5) (too-many-arguments)
This would be solved by refactoring the above.