Skip to content

Commit 7e70730

Browse files
Add effect enumeration
1 parent 02e33f4 commit 7e70730

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

causal_testing/testing/base_test_case.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
from dataclasses import dataclass
22
from causal_testing.specification.variable import Variable
3+
from causal_testing.testing.effect import Effect
34

45

56
@dataclass(frozen=True)
@@ -10,4 +11,4 @@ class BaseTestCase:
1011

1112
treatment_variable: Variable
1213
outcome_variable: Variable
13-
effect: str = "total"
14+
effect: str = Effect.total.value

causal_testing/testing/effect.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
from enum import Enum
2+
3+
4+
class Effect(Enum):
5+
"An enumeration of allowable effect types."
6+
total = "total"
7+
direct = "direct"

0 commit comments

Comments
 (0)