Skip to content

Commit

Permalink
Fix #280, fix #286
Browse files Browse the repository at this point in the history
  • Loading branch information
kbattocchi committed Oct 7, 2020
1 parent 3708718 commit 0490101
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 10 deletions.
1 change: 1 addition & 0 deletions econml/cate_interpreter.py
Original file line number Diff line number Diff line change
Expand Up @@ -543,6 +543,7 @@ def interpret(self, cate_estimator, X, sample_treatment_costs=None, treatment_na
splitter=self.splitter,
max_depth=self.max_depth,
min_samples_split=self.min_samples_split,
min_samples_leaf=self.min_samples_leaf,
min_weight_fraction_leaf=self.min_weight_fraction_leaf,
max_features=self.max_features,
random_state=self.random_state,
Expand Down
11 changes: 1 addition & 10 deletions econml/ortho_iv.py
Original file line number Diff line number Diff line change
Expand Up @@ -1389,14 +1389,6 @@ class LinearIntentToTreatDRIV(StatsModelsCateEstimatorMixin, IntentToTreatDRIV):
Unless an iterable is used, we call `split(concat[W, X], T)` to generate the splits. If all
W, X are None, then we call `split(ones((T.shape[0], 1)), T)`.
opt_reweighted : bool, optional, default False
Whether to reweight the samples to minimize variance. If True then
final_model_effect.fit must accept sample_weight as a kw argument (WeightWrapper from
utilities can be used for any linear model to enable sample_weights). If True then
assumes the final_model_effect is flexible enough to fit the true CATE model. Otherwise,
it method will return a biased projection to the model_effect space, biased
to give more weight on parts of the feature space where the instrument is strong.
categories: 'auto' or list, default 'auto'
The categories to use when encoding discrete treatments (or 'auto' to use the unique sorted values).
The first category will be treated as the control treatment.
Expand All @@ -1409,14 +1401,13 @@ def __init__(self, model_Y_X, model_T_XZ,
fit_cate_intercept=True,
cov_clip=.1,
n_splits=3,
opt_reweighted=False,
categories='auto'):
super().__init__(model_Y_X, model_T_XZ,
flexible_model_effect=flexible_model_effect,
featurizer=featurizer,
fit_cate_intercept=fit_cate_intercept,
final_model_effect=StatsModelsLinearRegression(fit_intercept=False),
cov_clip=cov_clip, n_splits=n_splits, opt_reweighted=opt_reweighted,
cov_clip=cov_clip, n_splits=n_splits, opt_reweighted=False,
categories=categories)

# override only so that we can update the docstring to indicate support for `StatsModelsInference`
Expand Down

0 comments on commit 0490101

Please sign in to comment.