From 15e2193e128f86ef7bdea15389eec830fe1ea077 Mon Sep 17 00:00:00 2001 From: delta Date: Wed, 18 Sep 2024 12:56:30 -0400 Subject: [PATCH] Fixed imputation order handling in ImputationKernel - Fixed typo "decending" to "descending". - Updated sorting configuration for ascending order to use ascending=True. Related to issue #90 --- miceforest/imputation_kernel.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/miceforest/imputation_kernel.py b/miceforest/imputation_kernel.py index 7332a4a..873bf1a 100644 --- a/miceforest/imputation_kernel.py +++ b/miceforest/imputation_kernel.py @@ -183,9 +183,9 @@ def __init__( if key in self.imputed_variables } self.imputation_order = list( - Series(_na_counts).sort_values(ascending=False).index + Series(_na_counts).sort_values(ascending=True).index ) - if imputation_order == "decending": + if imputation_order == "descending": self.imputation_order.reverse() elif imputation_order == "roman": self.imputation_order = self.imputed_variables.copy()