{ "cells": [ { "cell_type": "code", "execution_count": 83, "id": "166e531b", "metadata": {}, "outputs": [], "source": [ "import pandas as pd\n", "import datetime\n", "import glob\n", "import re" ] }, { "cell_type": "code", "execution_count": 84, "id": "c65a1428", "metadata": {}, "outputs": [], "source": [ "pd.options.display.max_rows = 10" ] }, { "cell_type": "code", "execution_count": 85, "id": "037e13ee", "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", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
Raison SocialeSIRENAnnéeNoteStructureNom UESEntreprises UES (SIREN)RégionDépartementPays
0SAS HERNAS CARTONNAGE5520176201947.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
1SAS HERNAS CARTONNAGE5520176202088.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
2HERNAS CARTONNAGE5520176202188.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
3L'OISEAU BLEU5620190202094.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
4L'OISEAU BLEU5620190202188.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
.................................
16378SANDVIK MINING AND CONSTRUCTION FRANCE3345379742020NaNEntrepriseNaNNaNAuvergne-Rhône-AlpesRhôneFRANCE
16379SANDVIK MINING AND CONSTRUCTION FRANCE SAS334537974202154.0EntrepriseNaNNaNAuvergne-Rhône-AlpesRhôneFRANCE
16380pOLYCLINIQUE DE LA THIERACHE3345546232019NaNEntrepriseNaNNaNHauts-de-FranceNordFRANCE
16381POLYCLINIQUE DE LA THIERACHE3345546232020NaNEntrepriseNaNNaNHauts-de-FranceNordFRANCE
16382GEODIS CALBERSON AQUITAINE3345565372018NaNEntrepriseNaNNaNNouvelle-AquitaineGirondeFRANCE
\n", "

16383 rows × 10 columns

\n", "
" ], "text/plain": [ " Raison Sociale SIREN Année Note \\\n", "0 SAS HERNAS CARTONNAGE 5520176 2019 47.0 \n", "1 SAS HERNAS CARTONNAGE 5520176 2020 88.0 \n", "2 HERNAS CARTONNAGE 5520176 2021 88.0 \n", "3 L'OISEAU BLEU 5620190 2020 94.0 \n", "4 L'OISEAU BLEU 5620190 2021 88.0 \n", "... ... ... ... ... \n", "16378 SANDVIK MINING AND CONSTRUCTION FRANCE 334537974 2020 NaN \n", "16379 SANDVIK MINING AND CONSTRUCTION FRANCE SAS 334537974 2021 54.0 \n", "16380 pOLYCLINIQUE DE LA THIERACHE 334554623 2019 NaN \n", "16381 POLYCLINIQUE DE LA THIERACHE 334554623 2020 NaN \n", "16382 GEODIS CALBERSON AQUITAINE 334556537 2018 NaN \n", "\n", " Structure Nom UES Entreprises UES (SIREN) Région \\\n", "0 Entreprise NaN NaN Hauts-de-France \n", "1 Entreprise NaN NaN Hauts-de-France \n", "2 Entreprise NaN NaN Hauts-de-France \n", "3 Entreprise NaN NaN Hauts-de-France \n", "4 Entreprise NaN NaN Hauts-de-France \n", "... ... ... ... ... \n", "16378 Entreprise NaN NaN Auvergne-Rhône-Alpes \n", "16379 Entreprise NaN NaN Auvergne-Rhône-Alpes \n", "16380 Entreprise NaN NaN Hauts-de-France \n", "16381 Entreprise NaN NaN Hauts-de-France \n", "16382 Entreprise NaN NaN Nouvelle-Aquitaine \n", "\n", " Département Pays \n", "0 Somme FRANCE \n", "1 Somme FRANCE \n", "2 Somme FRANCE \n", "3 Somme FRANCE \n", "4 Somme FRANCE \n", "... ... ... \n", "16378 Rhône FRANCE \n", "16379 Rhône FRANCE \n", "16380 Nord FRANCE \n", "16381 Nord FRANCE \n", "16382 Gironde FRANCE \n", "\n", "[16383 rows x 10 columns]" ] }, "execution_count": 85, "metadata": {}, "output_type": "execute_result" } ], "source": [ "propre3 = pd.read_excel('index-egalite-fh.xls')\n", "propre3" ] }, { "cell_type": "code", "execution_count": 86, "id": "3a5e9ce5", "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", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
Raison SocialeSIRENAnnéeNoteStructureNom UESEntreprises UES (SIREN)RégionDépartementPays
0SAS HERNAS CARTONNAGE5520176201947.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
1SAS HERNAS CARTONNAGE5520176202088.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
2HERNAS CARTONNAGE5520176202188.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
3L'OISEAU BLEU5620190202094.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
4L'OISEAU BLEU5620190202188.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
.................................
16378SANDVIK MINING AND CONSTRUCTION FRANCE3345379742020NaNEntrepriseNaNNaNAuvergne-Rhône-AlpesRhôneFRANCE
16379SANDVIK MINING AND CONSTRUCTION FRANCE SAS334537974202154.0EntrepriseNaNNaNAuvergne-Rhône-AlpesRhôneFRANCE
16380pOLYCLINIQUE DE LA THIERACHE3345546232019NaNEntrepriseNaNNaNHauts-de-FranceNordFRANCE
16381POLYCLINIQUE DE LA THIERACHE3345546232020NaNEntrepriseNaNNaNHauts-de-FranceNordFRANCE
16382GEODIS CALBERSON AQUITAINE3345565372018NaNEntrepriseNaNNaNNouvelle-AquitaineGirondeFRANCE
\n", "

16383 rows × 10 columns

\n", "
" ], "text/plain": [ " Raison Sociale SIREN Année Note \\\n", "0 SAS HERNAS CARTONNAGE 5520176 2019 47.0 \n", "1 SAS HERNAS CARTONNAGE 5520176 2020 88.0 \n", "2 HERNAS CARTONNAGE 5520176 2021 88.0 \n", "3 L'OISEAU BLEU 5620190 2020 94.0 \n", "4 L'OISEAU BLEU 5620190 2021 88.0 \n", "... ... ... ... ... \n", "16378 SANDVIK MINING AND CONSTRUCTION FRANCE 334537974 2020 NaN \n", "16379 SANDVIK MINING AND CONSTRUCTION FRANCE SAS 334537974 2021 54.0 \n", "16380 pOLYCLINIQUE DE LA THIERACHE 334554623 2019 NaN \n", "16381 POLYCLINIQUE DE LA THIERACHE 334554623 2020 NaN \n", "16382 GEODIS CALBERSON AQUITAINE 334556537 2018 NaN \n", "\n", " Structure Nom UES Entreprises UES (SIREN) Région \\\n", "0 Entreprise NaN NaN Hauts-de-France \n", "1 Entreprise NaN NaN Hauts-de-France \n", "2 Entreprise NaN NaN Hauts-de-France \n", "3 Entreprise NaN NaN Hauts-de-France \n", "4 Entreprise NaN NaN Hauts-de-France \n", "... ... ... ... ... \n", "16378 Entreprise NaN NaN Auvergne-Rhône-Alpes \n", "16379 Entreprise NaN NaN Auvergne-Rhône-Alpes \n", "16380 Entreprise NaN NaN Hauts-de-France \n", "16381 Entreprise NaN NaN Hauts-de-France \n", "16382 Entreprise NaN NaN Nouvelle-Aquitaine \n", "\n", " Département Pays \n", "0 Somme FRANCE \n", "1 Somme FRANCE \n", "2 Somme FRANCE \n", "3 Somme FRANCE \n", "4 Somme FRANCE \n", "... ... ... \n", "16378 Rhône FRANCE \n", "16379 Rhône FRANCE \n", "16380 Nord FRANCE \n", "16381 Nord FRANCE \n", "16382 Gironde FRANCE \n", "\n", "[16383 rows x 10 columns]" ] }, "execution_count": 86, "metadata": {}, "output_type": "execute_result" } ], "source": [ "cols = [x for x in range (propre3.shape[1])]\n", "propre3 = pd.read_excel('index-egalite-fh.xls', usecols=cols)\n", "propre3" ] }, { "cell_type": "code", "execution_count": 82, "id": "4ab71567", "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", "
Raison SocialeSIRENAnnéeNoteStructureNom UESEntreprises UES (SIREN)RégionDépartementPays
\n", "
" ], "text/plain": [ "Empty DataFrame\n", "Columns: [Raison Sociale, SIREN, Année, Note, Structure, Nom UES, Entreprises UES (SIREN), Région, Département, Pays]\n", "Index: []" ] }, "execution_count": 82, "metadata": {}, "output_type": "execute_result" } ], "source": [ "propre3.isnull()" ] }, { "cell_type": "code", "execution_count": 76, "id": "da27db27", "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", "
Raison SocialeSIRENAnnéeNoteStructureNom UESEntreprises UES (SIREN)RégionDépartementPays
\n", "
" ], "text/plain": [ "Empty DataFrame\n", "Columns: [Raison Sociale, SIREN, Année, Note, Structure, Nom UES, Entreprises UES (SIREN), Région, Département, Pays]\n", "Index: []" ] }, "execution_count": 76, "metadata": {}, "output_type": "execute_result" } ], "source": [ "propre3.dropna(thresh=10, inplace=True)\n", "propre3" ] }, { "cell_type": "code", "execution_count": 87, "id": "9e1d69dd", "metadata": {}, "outputs": [ { "data": { "text/plain": [ "0 False\n", "1 False\n", "2 False\n", "3 False\n", "4 False\n", " ... \n", "16378 False\n", "16379 False\n", "16380 False\n", "16381 False\n", "16382 False\n", "Length: 16383, dtype: bool" ] }, "execution_count": 87, "metadata": {}, "output_type": "execute_result" } ], "source": [ "propre3.duplicated()" ] }, { "cell_type": "code", "execution_count": 88, "id": "3eeb3630", "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", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
Raison SocialeSIRENAnnéeNoteStructureNom UESEntreprises UES (SIREN)RégionDépartementPays
0SAS HERNAS CARTONNAGE5520176201947.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
1SAS HERNAS CARTONNAGE5520176202088.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
2HERNAS CARTONNAGE5520176202188.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
3L'OISEAU BLEU5620190202094.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
4L'OISEAU BLEU5620190202188.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
.................................
16378SANDVIK MINING AND CONSTRUCTION FRANCE3345379742020NaNEntrepriseNaNNaNAuvergne-Rhône-AlpesRhôneFRANCE
16379SANDVIK MINING AND CONSTRUCTION FRANCE SAS334537974202154.0EntrepriseNaNNaNAuvergne-Rhône-AlpesRhôneFRANCE
16380pOLYCLINIQUE DE LA THIERACHE3345546232019NaNEntrepriseNaNNaNHauts-de-FranceNordFRANCE
16381POLYCLINIQUE DE LA THIERACHE3345546232020NaNEntrepriseNaNNaNHauts-de-FranceNordFRANCE
16382GEODIS CALBERSON AQUITAINE3345565372018NaNEntrepriseNaNNaNNouvelle-AquitaineGirondeFRANCE
\n", "

16383 rows × 10 columns

\n", "
" ], "text/plain": [ " Raison Sociale SIREN Année Note \\\n", "0 SAS HERNAS CARTONNAGE 5520176 2019 47.0 \n", "1 SAS HERNAS CARTONNAGE 5520176 2020 88.0 \n", "2 HERNAS CARTONNAGE 5520176 2021 88.0 \n", "3 L'OISEAU BLEU 5620190 2020 94.0 \n", "4 L'OISEAU BLEU 5620190 2021 88.0 \n", "... ... ... ... ... \n", "16378 SANDVIK MINING AND CONSTRUCTION FRANCE 334537974 2020 NaN \n", "16379 SANDVIK MINING AND CONSTRUCTION FRANCE SAS 334537974 2021 54.0 \n", "16380 pOLYCLINIQUE DE LA THIERACHE 334554623 2019 NaN \n", "16381 POLYCLINIQUE DE LA THIERACHE 334554623 2020 NaN \n", "16382 GEODIS CALBERSON AQUITAINE 334556537 2018 NaN \n", "\n", " Structure Nom UES Entreprises UES (SIREN) Région \\\n", "0 Entreprise NaN NaN Hauts-de-France \n", "1 Entreprise NaN NaN Hauts-de-France \n", "2 Entreprise NaN NaN Hauts-de-France \n", "3 Entreprise NaN NaN Hauts-de-France \n", "4 Entreprise NaN NaN Hauts-de-France \n", "... ... ... ... ... \n", "16378 Entreprise NaN NaN Auvergne-Rhône-Alpes \n", "16379 Entreprise NaN NaN Auvergne-Rhône-Alpes \n", "16380 Entreprise NaN NaN Hauts-de-France \n", "16381 Entreprise NaN NaN Hauts-de-France \n", "16382 Entreprise NaN NaN Nouvelle-Aquitaine \n", "\n", " Département Pays \n", "0 Somme FRANCE \n", "1 Somme FRANCE \n", "2 Somme FRANCE \n", "3 Somme FRANCE \n", "4 Somme FRANCE \n", "... ... ... \n", "16378 Rhône FRANCE \n", "16379 Rhône FRANCE \n", "16380 Nord FRANCE \n", "16381 Nord FRANCE \n", "16382 Gironde FRANCE \n", "\n", "[16383 rows x 10 columns]" ] }, "execution_count": 88, "metadata": {}, "output_type": "execute_result" } ], "source": [ "propre3.drop_duplicates()" ] }, { "cell_type": "code", "execution_count": 44, "id": "98df451a", "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ "/var/folders/td/4cpgzdjd7fl57lzw14shn36m0000gn/T/ipykernel_20829/336442086.py:2: FutureWarning: The default value of regex will change from True to False in a future version. In addition, single character regular expressions will *not* be treated as literal strings when regex=True.\n", " propre2[\"Code_Dechet\"] = propre2[\"Code_Dechet\"].str.replace(\"*\", \"\")\n" ] }, { "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", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
SirenNom_EtablissementAnneeCode_Operation_Eliminatio_ValorisationLibelle_Operation_Eliminatio_ValorisationCode_DepartementCode_DechetLibelle_DechetQuantiteUnite
03012500ESTIA RESEAUX DE CHALEUR2020D10D10 Incinération à terre5711 01 11Liquides aqueux de rinçage contenant des subs...3.000tonnes/an
13012500ESTIA RESEAUX DE CHALEUR2020R1R1 Utilisation principale comme combustible ou...3713 02 08Autres huiles moteur, de boîte de vitesses et...2.000tonnes/an
23012500ESTIA RESEAUX DE CHALEUR2020R13R13 Stockage de déchets préalablement à l'u...3716 10 01Déchets liquides aqueux contenant des substan...0.494tonnes/an
33012500ESTIA RESEAUX DE CHALEUR2020R3R3 Recyclage ou récupération des substances ...4515 01 10Emballages contenant des résidus de substance...0.035tonnes/an
43012500ESTIA RESEAUX DE CHALEUR2020R4R4 Recyclage ou récupération des métaux et ...5716 06 03Piles contenant du mercure0.093tonnes/an
.................................
655309000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1613 05 06Hydrocarbures provenant de séparateurs eau/hy...1.000tonnes/an
655319000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1615 01 10Emballages contenant des résidus de substance...0.360tonnes/an
655329000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1615 02 02Absorbants, matériaux filtrants (y compris le...0.510tonnes/an
655339000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1616 01 07Filtres à huile0.810tonnes/an
655349000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1616 01 14Antigels contenant des substances dangereuses1.000tonnes/an
\n", "

64100 rows × 10 columns

\n", "
" ], "text/plain": [ " Siren Nom_Etablissement Annee \\\n", "0 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "1 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "2 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "3 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "4 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "... ... ... ... \n", "65530 9000029 BA 709 Cognac 2020 \n", "65531 9000029 BA 709 Cognac 2020 \n", "65532 9000029 BA 709 Cognac 2020 \n", "65533 9000029 BA 709 Cognac 2020 \n", "65534 9000029 BA 709 Cognac 2020 \n", "\n", " Code_Operation_Eliminatio_Valorisation \\\n", "0 D10 \n", "1 R1 \n", "2 R13 \n", "3 R3 \n", "4 R4 \n", "... ... \n", "65530 R13 \n", "65531 R13 \n", "65532 R13 \n", "65533 R13 \n", "65534 R13 \n", "\n", " Libelle_Operation_Eliminatio_Valorisation Code_Departement \\\n", "0 D10 Incinération à terre 57 \n", "1 R1 Utilisation principale comme combustible ou... 37 \n", "2 R13 Stockage de déchets préalablement à l'u... 37 \n", "3 R3 Recyclage ou récupération des substances ... 45 \n", "4 R4 Recyclage ou récupération des métaux et ... 57 \n", "... ... ... \n", "65530 R13 Stockage de déchets préalablement à l'u... 16 \n", "65531 R13 Stockage de déchets préalablement à l'u... 16 \n", "65532 R13 Stockage de déchets préalablement à l'u... 16 \n", "65533 R13 Stockage de déchets préalablement à l'u... 16 \n", "65534 R13 Stockage de déchets préalablement à l'u... 16 \n", "\n", " Code_Dechet Libelle_Dechet \\\n", "0 11 01 11 Liquides aqueux de rinçage contenant des subs... \n", "1 13 02 08 Autres huiles moteur, de boîte de vitesses et... \n", "2 16 10 01 Déchets liquides aqueux contenant des substan... \n", "3 15 01 10 Emballages contenant des résidus de substance... \n", "4 16 06 03 Piles contenant du mercure \n", "... ... ... \n", "65530 13 05 06 Hydrocarbures provenant de séparateurs eau/hy... \n", "65531 15 01 10 Emballages contenant des résidus de substance... \n", "65532 15 02 02 Absorbants, matériaux filtrants (y compris le... \n", "65533 16 01 07 Filtres à huile \n", "65534 16 01 14 Antigels contenant des substances dangereuses \n", "\n", " Quantite Unite \n", "0 3.000 tonnes/an \n", "1 2.000 tonnes/an \n", "2 0.494 tonnes/an \n", "3 0.035 tonnes/an \n", "4 0.093 tonnes/an \n", "... ... ... \n", "65530 1.000 tonnes/an \n", "65531 0.360 tonnes/an \n", "65532 0.510 tonnes/an \n", "65533 0.810 tonnes/an \n", "65534 1.000 tonnes/an \n", "\n", "[64100 rows x 10 columns]" ] }, "execution_count": 44, "metadata": {}, "output_type": "execute_result" } ], "source": [ "#propre2[\"Hommes 15-24\"] = chom[\"Hommes 15-24\"].astype(str)\n", "propre2[\"Code_Dechet\"] = propre2[\"Code_Dechet\"].str.replace(\"*\", \"\")\n", "propre2" ] }, { "cell_type": "code", "execution_count": 89, "id": "a0531825", "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", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
Raison SocialeSIRENAnnéeNoteStructureNom UESEntreprises UES (SIREN)RégionDépartementPays
0SAS HERNAS CARTONNAGE5520176201947.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
1SAS HERNAS CARTONNAGE5520176202088.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
2HERNAS CARTONNAGE5520176202188.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
3L'OISEAU BLEU5620190202094.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
4L'OISEAU BLEU5620190202188.0EntrepriseNaNNaNHauts-de-FranceSommeFRANCE
.................................
16378SANDVIK MINING AND CONSTRUCTION FRANCE3345379742020NaNEntrepriseNaNNaNAuvergne-Rhône-AlpesRhôneFRANCE
16379SANDVIK MINING AND CONSTRUCTION FRANCE SAS334537974202154.0EntrepriseNaNNaNAuvergne-Rhône-AlpesRhôneFRANCE
16380pOLYCLINIQUE DE LA THIERACHE3345546232019NaNEntrepriseNaNNaNHauts-de-FranceNordFRANCE
16381POLYCLINIQUE DE LA THIERACHE3345546232020NaNEntrepriseNaNNaNHauts-de-FranceNordFRANCE
16382GEODIS CALBERSON AQUITAINE3345565372018NaNEntrepriseNaNNaNNouvelle-AquitaineGirondeFRANCE
\n", "

16383 rows × 10 columns

\n", "
" ], "text/plain": [ " Raison Sociale SIREN Année Note \\\n", "0 SAS HERNAS CARTONNAGE 5520176 2019 47.0 \n", "1 SAS HERNAS CARTONNAGE 5520176 2020 88.0 \n", "2 HERNAS CARTONNAGE 5520176 2021 88.0 \n", "3 L'OISEAU BLEU 5620190 2020 94.0 \n", "4 L'OISEAU BLEU 5620190 2021 88.0 \n", "... ... ... ... ... \n", "16378 SANDVIK MINING AND CONSTRUCTION FRANCE 334537974 2020 NaN \n", "16379 SANDVIK MINING AND CONSTRUCTION FRANCE SAS 334537974 2021 54.0 \n", "16380 pOLYCLINIQUE DE LA THIERACHE 334554623 2019 NaN \n", "16381 POLYCLINIQUE DE LA THIERACHE 334554623 2020 NaN \n", "16382 GEODIS CALBERSON AQUITAINE 334556537 2018 NaN \n", "\n", " Structure Nom UES Entreprises UES (SIREN) Région \\\n", "0 Entreprise NaN NaN Hauts-de-France \n", "1 Entreprise NaN NaN Hauts-de-France \n", "2 Entreprise NaN NaN Hauts-de-France \n", "3 Entreprise NaN NaN Hauts-de-France \n", "4 Entreprise NaN NaN Hauts-de-France \n", "... ... ... ... ... \n", "16378 Entreprise NaN NaN Auvergne-Rhône-Alpes \n", "16379 Entreprise NaN NaN Auvergne-Rhône-Alpes \n", "16380 Entreprise NaN NaN Hauts-de-France \n", "16381 Entreprise NaN NaN Hauts-de-France \n", "16382 Entreprise NaN NaN Nouvelle-Aquitaine \n", "\n", " Département Pays \n", "0 Somme FRANCE \n", "1 Somme FRANCE \n", "2 Somme FRANCE \n", "3 Somme FRANCE \n", "4 Somme FRANCE \n", "... ... ... \n", "16378 Rhône FRANCE \n", "16379 Rhône FRANCE \n", "16380 Nord FRANCE \n", "16381 Nord FRANCE \n", "16382 Gironde FRANCE \n", "\n", "[16383 rows x 10 columns]" ] }, "execution_count": 89, "metadata": {}, "output_type": "execute_result" } ], "source": [ "propre3" ] }, { "cell_type": "code", "execution_count": 59, "id": "20b51a16", "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ "/var/folders/td/4cpgzdjd7fl57lzw14shn36m0000gn/T/ipykernel_20829/2049097812.py:2: FutureWarning: As the xlwt package is no longer maintained, the xlwt engine will be removed in a future version of pandas. This is the only engine in pandas that supports writing in the xls format. Install openpyxl and write to an xlsx file instead. You can set the option io.excel.xls.writer to 'xlwt' to silence this warning. While this option is deprecated and will also raise a warning, it can be globally set and the warning suppressed.\n", " propre2.to_excel(file_name)\n" ] }, { "name": "stdout", "output_type": "stream", "text": [ "DataFrame is written to Excel File successfully.\n" ] } ], "source": [ "file_name = 'ProdProp_Dechets_Dangereux.xls'\n", "propre2.to_excel(file_name)\n", "print('DataFrame is written to Excel File successfully.')" ] }, { "cell_type": "code", "execution_count": 60, "id": "7bf33a3e", "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", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
SirenNom_EtablissementAnneeCode_Operation_Eliminatio_ValorisationLibelle_Operation_Eliminatio_ValorisationCode_DepartementCode_DechetLibelle_DechetQuantiteUnite
03012500ESTIA RESEAUX DE CHALEUR2020D10D10 Incinération à terre5711 01 11*Liquides aqueux de rinçage contenant des subs...3.000tonnes/an
13012500ESTIA RESEAUX DE CHALEUR2020R1R1 Utilisation principale comme combustible ou...3713 02 08*Autres huiles moteur, de boîte de vitesses et...2.000tonnes/an
23012500ESTIA RESEAUX DE CHALEUR2020R13R13 Stockage de déchets préalablement à l'u...3716 10 01*Déchets liquides aqueux contenant des substan...0.494tonnes/an
33012500ESTIA RESEAUX DE CHALEUR2020R3R3 Recyclage ou récupération des substances ...4515 01 10*Emballages contenant des résidus de substance...0.035tonnes/an
43012500ESTIA RESEAUX DE CHALEUR2020R4R4 Recyclage ou récupération des métaux et ...5716 06 03*Piles contenant du mercure0.093tonnes/an
.................................
655309000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1613 05 06*Hydrocarbures provenant de séparateurs eau/hy...1.000tonnes/an
655319000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1615 01 10*Emballages contenant des résidus de substance...0.360tonnes/an
655329000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1615 02 02*Absorbants, matériaux filtrants (y compris le...0.510tonnes/an
655339000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1616 01 07*Filtres à huile0.810tonnes/an
655349000029BA 709 Cognac2020R13R13 Stockage de déchets préalablement à l'u...1616 01 14*Antigels contenant des substances dangereuses1.000tonnes/an
\n", "

64100 rows × 10 columns

\n", "
" ], "text/plain": [ " Siren Nom_Etablissement Annee \\\n", "0 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "1 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "2 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "3 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "4 3012500 ESTIA RESEAUX DE CHALEUR 2020 \n", "... ... ... ... \n", "65530 9000029 BA 709 Cognac 2020 \n", "65531 9000029 BA 709 Cognac 2020 \n", "65532 9000029 BA 709 Cognac 2020 \n", "65533 9000029 BA 709 Cognac 2020 \n", "65534 9000029 BA 709 Cognac 2020 \n", "\n", " Code_Operation_Eliminatio_Valorisation \\\n", "0 D10 \n", "1 R1 \n", "2 R13 \n", "3 R3 \n", "4 R4 \n", "... ... \n", "65530 R13 \n", "65531 R13 \n", "65532 R13 \n", "65533 R13 \n", "65534 R13 \n", "\n", " Libelle_Operation_Eliminatio_Valorisation Code_Departement \\\n", "0 D10 Incinération à terre 57 \n", "1 R1 Utilisation principale comme combustible ou... 37 \n", "2 R13 Stockage de déchets préalablement à l'u... 37 \n", "3 R3 Recyclage ou récupération des substances ... 45 \n", "4 R4 Recyclage ou récupération des métaux et ... 57 \n", "... ... ... \n", "65530 R13 Stockage de déchets préalablement à l'u... 16 \n", "65531 R13 Stockage de déchets préalablement à l'u... 16 \n", "65532 R13 Stockage de déchets préalablement à l'u... 16 \n", "65533 R13 Stockage de déchets préalablement à l'u... 16 \n", "65534 R13 Stockage de déchets préalablement à l'u... 16 \n", "\n", " Code_Dechet Libelle_Dechet \\\n", "0 11 01 11* Liquides aqueux de rinçage contenant des subs... \n", "1 13 02 08* Autres huiles moteur, de boîte de vitesses et... \n", "2 16 10 01* Déchets liquides aqueux contenant des substan... \n", "3 15 01 10* Emballages contenant des résidus de substance... \n", "4 16 06 03* Piles contenant du mercure \n", "... ... ... \n", "65530 13 05 06* Hydrocarbures provenant de séparateurs eau/hy... \n", "65531 15 01 10* Emballages contenant des résidus de substance... \n", "65532 15 02 02* Absorbants, matériaux filtrants (y compris le... \n", "65533 16 01 07* Filtres à huile \n", "65534 16 01 14* Antigels contenant des substances dangereuses \n", "\n", " Quantite Unite \n", "0 3.000 tonnes/an \n", "1 2.000 tonnes/an \n", "2 0.494 tonnes/an \n", "3 0.035 tonnes/an \n", "4 0.093 tonnes/an \n", "... ... ... \n", "65530 1.000 tonnes/an \n", "65531 0.360 tonnes/an \n", "65532 0.510 tonnes/an \n", "65533 0.810 tonnes/an \n", "65534 1.000 tonnes/an \n", "\n", "[64100 rows x 10 columns]" ] }, "execution_count": 60, "metadata": {}, "output_type": "execute_result" } ], "source": [ "propre2" ] }, { "cell_type": "code", "execution_count": null, "id": "fbfa5f57", "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.9.7" } }, "nbformat": 4, "nbformat_minor": 5 }