Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
sdaza committed Jan 1, 2025
1 parent 2252f7b commit 87d4cfa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion experiment_utils/estimators.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ def ipw_xgboost(self, data: pd.DataFrame, covariates: List[str]) -> pd.DataFrame
data['propensity_score'] = xgb_model.predict_proba(X)[:, 1]
data['propensity_score'] = np.minimum(self.max_ps_score, data['propensity_score'])
data['propensity_score'] = np.maximum(self.min_ps_score, data['propensity_score'])
data = self.___calculate_stabilized_weights(data)
data = self.__calculate_stabilized_weights(data)
return data

def __calculate_stabilized_weights(self, data: pd.DataFrame) -> pd.DataFrame:
Expand Down

0 comments on commit 87d4cfa

Please sign in to comment.