INNER CODE UNIT · Python

_get_candidate_preds_mice

AnotherSamWilson/miceforest · miceforest/imputation_kernel.py:753

    def _get_candidate_preds_mice(
        self,
        variable: str,
        lgbmodel: Booster,
        candidate_features: DataFrame,
        dataset: int,
        iteration: int,
    ) -> DataFrame:
        """
        This function also records the candidate predictions
        """
        shap = self.mean_match_strategy[variable] == "shap"
        fast = self.mean_match_strategy[variable] == "fast"
        logistic = variable not in self.modeled_numeric_columns

        assert hasattr(
            lgbmodel, "train_set"
        ), "Model was passed that does not have training data."

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…