From b8a89b9489eaf1832963484ed7f05e0556e30825 Mon Sep 17 00:00:00 2001 From: frodrigue-ensae Date: Mon, 15 Jan 2024 20:11:58 +0000 Subject: [PATCH] finale --- Traitement_Fanta.ipynb | 348 ----------------------------------------- 1 file changed, 348 deletions(-) diff --git a/Traitement_Fanta.ipynb b/Traitement_Fanta.ipynb index c4e2e6d..5e3529d 100644 --- a/Traitement_Fanta.ipynb +++ b/Traitement_Fanta.ipynb @@ -1401,265 +1401,6 @@ "base1=products.merge(pricing_formulas, how='left', left_on= 'pricing_formula_id', right_on= 'id', suffixes = (\"_products\", \"_pricing_formula\"))" ] }, - { - "cell_type": "code", - "execution_count": 75, - "id": "7dd0bdae-c1c5-44ba-a446-42b28def2343", - "metadata": {}, - "outputs": [ - { - "data": { - "text/html": [ - "
\n", - "\n", - "\n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - "
id_productsamountis_full_pricerepresentation_idpricing_formula_idcreated_at_productsupdated_at_productscategory_idapply_priceproducts_group_idproduct_pack_idextra_field_productsamount_consumptionidentifier_productsid_pricing_formulanamecreated_at_pricing_formulaupdated_at_pricing_formulaextra_field_pricing_formulaidentifier_pricing_formula
0106829.0False9141142020-09-03 14:09:43.119798+02:002020-09-03 14:09:43.119798+02:00410.0106551NaNNaN35c88f2db8a63d7474e46eb8ca9260e7114visite guidée indiv tr2020-09-03 13:21:21.397923+02:002022-02-18 15:57:55.792581+01:00NaN039003ae0b0cd2df183786804b713470
14789.5False2731312020-09-03 13:21:22.711773+02:002020-09-03 13:21:22.711773+02:0010.04711NaNNaN8a179671ab198e570e6a104c4451379f131billet mucem tp - picasso2020-09-03 13:21:21.410521+02:002022-02-18 15:57:55.792581+01:00NaN916c92362b8e7767715bc966de43e32b
22087311.5False2751372020-09-03 14:46:33.589030+02:002020-09-03 14:46:33.589030+02:0010.0208251NaNNaNee83779ce29e67ad251e40234b426d6a137billet mucem tp - pic. + guide2020-09-03 13:21:21.414922+02:002022-02-18 15:57:55.792581+01:00NaN91dd2ee46f5f2d78af989019ebd60a60
31571428.0False8251992022-01-28 19:29:23.525722+01:002022-01-28 19:29:23.525722+01:0050.01567731NaNNaNd865383579314b791aa4bcf3fb418f179billet mucem ts2020-09-03 13:11:23.997074+02:002022-02-18 15:57:55.792581+01:00NaN37532348a1f1ef1cb916c55ebaf8345c
413418.5False9932020-09-03 13:29:30.773089+02:002020-09-03 13:29:30.773089+02:0010.011751NaNNaNf1c4689bc47dee6f60b56d74b593dd4693billet mucem tr + guide2020-09-03 13:21:21.382586+02:002022-02-18 15:57:55.792581+01:00NaN722a8610e4391c27f2ec6f1224b42b3d
\n", - "
" - ], - "text/plain": [ - " id_products amount is_full_price representation_id pricing_formula_id \\\n", - "0 10682 9.0 False 914 114 \n", - "1 478 9.5 False 273 131 \n", - "2 20873 11.5 False 275 137 \n", - "3 157142 8.0 False 82519 9 \n", - "4 1341 8.5 False 9 93 \n", - "\n", - " created_at_products updated_at_products \\\n", - "0 2020-09-03 14:09:43.119798+02:00 2020-09-03 14:09:43.119798+02:00 \n", - "1 2020-09-03 13:21:22.711773+02:00 2020-09-03 13:21:22.711773+02:00 \n", - "2 2020-09-03 14:46:33.589030+02:00 2020-09-03 14:46:33.589030+02:00 \n", - "3 2022-01-28 19:29:23.525722+01:00 2022-01-28 19:29:23.525722+01:00 \n", - "4 2020-09-03 13:29:30.773089+02:00 2020-09-03 13:29:30.773089+02:00 \n", - "\n", - " category_id apply_price products_group_id product_pack_id \\\n", - "0 41 0.0 10655 1 \n", - "1 1 0.0 471 1 \n", - "2 1 0.0 20825 1 \n", - "3 5 0.0 156773 1 \n", - "4 1 0.0 1175 1 \n", - "\n", - " extra_field_products amount_consumption identifier_products \\\n", - "0 NaN NaN 35c88f2db8a63d7474e46eb8ca9260e7 \n", - "1 NaN NaN 8a179671ab198e570e6a104c4451379f \n", - "2 NaN NaN ee83779ce29e67ad251e40234b426d6a \n", - "3 NaN NaN d865383579314b791aa4bcf3fb418f17 \n", - "4 NaN NaN f1c4689bc47dee6f60b56d74b593dd46 \n", - "\n", - " id_pricing_formula name \\\n", - "0 114 visite guidée indiv tr \n", - "1 131 billet mucem tp - picasso \n", - "2 137 billet mucem tp - pic. + guide \n", - "3 9 billet mucem ts \n", - "4 93 billet mucem tr + guide \n", - "\n", - " created_at_pricing_formula updated_at_pricing_formula \\\n", - "0 2020-09-03 13:21:21.397923+02:00 2022-02-18 15:57:55.792581+01:00 \n", - "1 2020-09-03 13:21:21.410521+02:00 2022-02-18 15:57:55.792581+01:00 \n", - "2 2020-09-03 13:21:21.414922+02:00 2022-02-18 15:57:55.792581+01:00 \n", - "3 2020-09-03 13:11:23.997074+02:00 2022-02-18 15:57:55.792581+01:00 \n", - "4 2020-09-03 13:21:21.382586+02:00 2022-02-18 15:57:55.792581+01:00 \n", - "\n", - " extra_field_pricing_formula identifier_pricing_formula \n", - "0 NaN 039003ae0b0cd2df183786804b713470 \n", - "1 NaN 916c92362b8e7767715bc966de43e32b \n", - "2 NaN 91dd2ee46f5f2d78af989019ebd60a60 \n", - "3 NaN 37532348a1f1ef1cb916c55ebaf8345c \n", - "4 NaN 722a8610e4391c27f2ec6f1224b42b3d " - ] - }, - "execution_count": 75, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "base1.head(5)" - ] - }, - { - "cell_type": "code", - "execution_count": 77, - "id": "d8ef07cf-29a3-40fb-a3d7-bf32a729c053", - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "id 0\n", - "percent_price 0\n", - "max_price 0\n", - "min_price 0\n", - "category_id 0\n", - "pricing_formula_id 0\n", - "representation_id 0\n", - "created_at 0\n", - "updated_at 0\n", - "dtype: int64" - ] - }, - "execution_count": 77, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "products_groups.isna().sum()" - ] - }, { "cell_type": "code", "execution_count": 78, @@ -1682,95 +1423,6 @@ "base3=base2.merge(type_of_pricing_formulas, how='left', left_on= 'id_pricing_formula', right_on= 'pricing_formula_id', suffixes = (\"_merge3\", \"_type_of_pricing_f\"))" ] }, - { - "cell_type": "code", - "execution_count": 82, - "id": "508a8082-da34-4d2f-bfa9-9ca7703c3fda", - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "id 0\n", - "type_of_id 0\n", - "pricing_formula_id 0\n", - "created_at 0\n", - "updated_at 0\n", - "identifier 0\n", - "dtype: int64" - ] - }, - "execution_count": 82, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "type_of_pricing_formulas.isna().sum()" - ] - }, - { - "cell_type": "code", - "execution_count": 83, - "id": "0e255d11-57eb-47ca-afd3-31f59b8d8822", - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "id 0\n", - "amount 0\n", - "is_full_price 0\n", - "representation_id 0\n", - "pricing_formula_id 0\n", - "created_at 0\n", - "updated_at 0\n", - "category_id 0\n", - "apply_price 0\n", - "products_group_id 0\n", - "product_pack_id 0\n", - "extra_field 94803\n", - "amount_consumption 94803\n", - "identifier 0\n", - "dtype: int64" - ] - }, - "execution_count": 83, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "products.isna().sum()" - ] - }, - { - "cell_type": "code", - "execution_count": 84, - "id": "3f034e65-1b33-4908-b7e6-60660ef251c6", - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "id 0\n", - "name 1\n", - "type_of 0\n", - "created_at 0\n", - "updated_at 0\n", - "identifier 0\n", - "dtype: int64" - ] - }, - "execution_count": 84, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "product_packs.isna().sum()" - ] - }, { "cell_type": "code", "execution_count": 89,