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

Correct default value of alphas #476

Merged
merged 11 commits into from
Aug 9, 2021
10 changes: 5 additions & 5 deletions econml/inference/_inference.py
Original file line number Diff line number Diff line change
Expand Up @@ -1143,8 +1143,8 @@ class PopulationSummaryResults:

"""

def __init__(self, pred, pred_stderr, mean_pred_stderr, d_t, d_y, alpha, value, decimals, tol,
output_names=None, treatment_names=None):
def __init__(self, pred, pred_stderr, mean_pred_stderr, d_t, d_y, value, decimals, tol,
alpha=.1, output_names=None, treatment_names=None):
self.pred = pred
self.pred_stderr = pred_stderr
self.mean_pred_stderr = mean_pred_stderr
Expand Down Expand Up @@ -1242,7 +1242,7 @@ def pvalue(self, *, value=0):
pvalue = norm.sf(np.abs(self.zstat(value=value)), loc=0, scale=1) * 2
return pvalue

def conf_int_mean(self, *, alpha=.1):
def conf_int_mean(self, *, alpha=None):
mtanghu marked this conversation as resolved.
Show resolved Hide resolved
"""
Get the confidence interval of the mean point estimate of each treatment on each outcome for sample X.

Expand Down Expand Up @@ -1287,7 +1287,7 @@ def std_point(self):
"""
return np.std(self.pred, axis=0)

def percentile_point(self, *, alpha=.1):
def percentile_point(self, *, alpha=None):
"""
Get the confidence interval of the point estimate of each treatment on each outcome for sample X.

Expand All @@ -1310,7 +1310,7 @@ def percentile_point(self, *, alpha=.1):
upper_percentile_point = np.percentile(self.pred, (1 - alpha / 2) * 100, axis=0)
return lower_percentile_point, upper_percentile_point

def conf_int_point(self, *, alpha=.1, tol=.001):
def conf_int_point(self, *, alpha=None, tol=.001):
mtanghu marked this conversation as resolved.
Show resolved Hide resolved
"""
Get the confidence interval of the point estimate of each treatment on each outcome for sample X.

Expand Down