From 15125ef6dbdf52e15520f1c8a98b9b5dfe9adbd0 Mon Sep 17 00:00:00 2001 From: ajoubrel-ensae Date: Tue, 13 Feb 2024 22:42:13 +0000 Subject: [PATCH] Nettoyage --- 2_Regression_logistique.ipynb | 26 -------------------------- 1 file changed, 26 deletions(-) diff --git a/2_Regression_logistique.ipynb b/2_Regression_logistique.ipynb index 75dca1a..501ee86 100644 --- a/2_Regression_logistique.ipynb +++ b/2_Regression_logistique.ipynb @@ -27,32 +27,6 @@ "import matplotlib.pyplot as plt" ] }, - { - "cell_type": "code", - "execution_count": 2, - "id": "59ce5096-4e2c-45c1-be78-43e14db4142c", - "metadata": {}, - "outputs": [], - "source": [ - "# # modification des variables categorielles\n", - " \n", - "# ### variable gender\n", - "# df1_customer_product[\"gender_label\"] = df1_customer_product[\"gender\"].map({\n", - "# 0: 'female',\n", - "# 1: 'male',\n", - "# 2: 'other'\n", - "# })\n", - " \n", - "# ### variable country -> on indique si le pays est france\n", - "# df1_customer_product[\"country_fr\"] = df1_customer_product[\"country\"].apply(lambda x : int(x==\"fr\") if pd.notna(x) else np.nan)\n", - "\n", - "# # Création des indicatrices de gender\n", - "# gender_dummies = pd.get_dummies(df1_customer_product[\"gender_label\"], prefix='gender').astype(int)\n", - " \n", - "# # Concaténation des indicatrices avec le dataframe d'origine\n", - "# df1_customer_product = pd.concat([df1_customer_product, gender_dummies], axis=1)" - ] - }, { "cell_type": "code", "execution_count": 3,