{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Data gemeenteraadsverkiezingen 2022 Nederland\n",
    "\n",
    "Dit notebook is voor het verwerken van de data van de gemeenteraadsverkiezingen van 2022. Er zal hier stap voor stap door de data gelopen worden om het proces reproduceerbaar te maken voor latere verkiezingen. De eerste stap was de data ophalen van de bronnen, zowel de overheid als waar is mijn stemlokaal (voor geografische data van de stemlokalen). De bronnen gebruikt voor de data zijn voor de verkiezingen van 2022 is als volgt:\n",
    "\n",
    "- [Verkiezingsuitslagen Gemeenteraad 2022](https://data.overheid.nl/dataset/08b04bec-3332-4c76-bb0c-68bfaeb5df43)\n",
    "  - [Directe link naar uitslagen per gemeente CSV](https://data.overheid.nl/sites/default/files/dataset/08b04bec-3332-4c76-bb0c-68bfaeb5df43/resources/GR2022_2022-03-29T15.14.zip)\n",
    "  - [Directe link naar kandidatenlijst met uitslagen CSV](https://data.overheid.nl/sites/default/files/dataset/08b04bec-3332-4c76-bb0c-68bfaeb5df43/resources/GR2022_alle-kandidaten_2022-02-22T08.34.csv)\n",
    "- [Waar is mijn stemlokaal stembureau data](https://waarismijnstemlokaal.nl/data)\n",
    "  - [Directe link naar waar is mijn stemlokaal gemeenteraad 2022 CSV (CKAN)](https://ckan.dataplatform.nl/datastore/dump/d6a1b4c4-73c8-457b-9b75-a38428bded68)\n",
    "  - [Verkiezingsuitslagen gemeenteraadsverkiezingen 2022 geodata (Volkskrant)](https://data.openstate.eu/dataset/verkiezingsuitslagen-gemeenteraadsverkiezingen-2022)\n",
    "    - [Directe link naar GEOJSON bestand](https://data.openstate.eu/dataset/a1767f1b-bf0c-409b-b3b1-3af9954b57f4/resource/413be255-5070-48f4-b631-895097976abb/download/2022gr.geo.json)\n",
    "- [CBS Wijk- en buurtkaart 2021](https://www.cbs.nl/nl-nl/dossier/nederland-regionaal/geografische-data/wijk-en-buurtkaart-2021)\n",
    "  - [Directe link naar zip bestand met SHP bestand er in](https://www.cbs.nl/-/media/cbs/dossiers/nederland-regionaal/wijk-en-buurtstatistieken/wijkbuurtkaart_2021_v1.zip)\n",
    "- [CBS bevolkingsdichtheid kaart 100 bij 100 meter](https://www.cbs.nl/nl-nl/dossier/nederland-regionaal/geografische-data/kaart-van-100-meter-bij-100-meter-met-statistieken)\n",
    "  - [Directe link naar 7z bestand met SHP bestand er in](https://www.cbs.nl/-/media/cbs/dossiers/nederland-regionaal/vierkanten/100/nl_vierkant_100meter_bij_100meter.7z)\n",
    "- [CBS bevolkingsdichtheid kaart 500 bij 500 meter](https://www.cbs.nl/nl-nl/dossier/nederland-regionaal/geografische-data/kaart-van-500-meter-bij-500-meter-met-statistieken)\n",
    "  - [Directe link naar 7z bestand met SHP bestand er in](https://www.cbs.nl/-/media/cbs/dossiers/nederland-regionaal/vierkanten/500/2021-cbs_vk500_2020_v1.zip)\n",
    "\n",
    "De eerste stap die we moeten maken is de data importeren voor de analyse, daarna kunnen we kijken hoe goed de data is, hoe we het aan kunnen vullen, en wat er mee te doen. De makkelijkste structuur die we vonden was het geojson bestand van open state en de Volkskrant, daar staan alle stembureaus al in een lijst, en we hebben een makkelijk framework om het te importeren; geopandas. We laden deze dan ook als eerste in."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/home/lillian/.local/lib/python3.9/site-packages/fiona/collection.py:208: FeatureWarning: Empty field name at index 61\n",
      "  self._schema = self.session.get_schema()\n",
      "/home/lillian/anaconda3/lib/python3.9/site-packages/geopandas/geodataframe.py:600: UserWarning: Empty field name at index 61\n",
      "  for feature in features_lst:\n"
     ]
    }
   ],
   "source": [
    "import pandas as pd\n",
    "import geopandas as gpd\n",
    "\n",
    "crs = {'init':'EPSG:4326'}\n",
    "df_geojson = gpd.read_file(r'../data/2022gr.geo.json', crs=crs)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "We importeren nu de gemeente shapefile kaart van het CBS, om de overlay van onze stemlokalen eroverheen te kunnen doen. "
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<AxesSubplot:>"
      ]
     },
     "execution_count": 2,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "[encoded data, 43072 characters]",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "nl_map = gpd.read_file(r'../data/shape/Netherlands_shapefile/gemeente_2021_v1.shp')\n",
    "nl_map.to_crs(epsg=4326).plot()\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 29,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>GM_CODE</th>\n",
       "      <th>GM_NAAM</th>\n",
       "      <th>H2O</th>\n",
       "      <th>OAD</th>\n",
       "      <th>STED</th>\n",
       "      <th>BEV_DICHTH</th>\n",
       "      <th>AANT_INW</th>\n",
       "      <th>AANT_MAN</th>\n",
       "      <th>AANT_VROUW</th>\n",
       "      <th>P_00_14_JR</th>\n",
       "      <th>...</th>\n",
       "      <th>P_TURKIJE</th>\n",
       "      <th>P_OVER_NW</th>\n",
       "      <th>OPP_TOT</th>\n",
       "      <th>OPP_LAND</th>\n",
       "      <th>OPP_WATER</th>\n",
       "      <th>JRSTATCODE</th>\n",
       "      <th>JAAR</th>\n",
       "      <th>Shape_Leng</th>\n",
       "      <th>Shape_Area</th>\n",
       "      <th>geometry</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>GM0034</td>\n",
       "      <td>Almere</td>\n",
       "      <td>JA</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>...</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>2021GM0034</td>\n",
       "      <td>2021</td>\n",
       "      <td>122665.358635</td>\n",
       "      <td>1.095623e+08</td>\n",
       "      <td>MULTIPOLYGON (((150213.998 479503.726, 150087....</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>GM0050</td>\n",
       "      <td>Zeewolde</td>\n",
       "      <td>JA</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>...</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>2021GM0050</td>\n",
       "      <td>2021</td>\n",
       "      <td>83290.773617</td>\n",
       "      <td>1.633050e+07</td>\n",
       "      <td>MULTIPOLYGON (((170588.413 486792.192, 170570....</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>2</th>\n",
       "      <td>GM0060</td>\n",
       "      <td>Ameland</td>\n",
       "      <td>JA</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>...</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>2021GM0060</td>\n",
       "      <td>2021</td>\n",
       "      <td>156406.894023</td>\n",
       "      <td>2.085914e+08</td>\n",
       "      <td>POLYGON ((196000.000 610000.000, 196000.000 60...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>3</th>\n",
       "      <td>GM0072</td>\n",
       "      <td>Harlingen</td>\n",
       "      <td>JA</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>...</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>2021GM0072</td>\n",
       "      <td>2021</td>\n",
       "      <td>104274.683035</td>\n",
       "      <td>3.618323e+08</td>\n",
       "      <td>MULTIPOLYGON (((158392.775 580357.500, 158387....</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>4</th>\n",
       "      <td>GM0088</td>\n",
       "      <td>Schiermonnikoog</td>\n",
       "      <td>JA</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>...</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>-99999999</td>\n",
       "      <td>2021GM0088</td>\n",
       "      <td>2021</td>\n",
       "      <td>152568.858991</td>\n",
       "      <td>1.624101e+08</td>\n",
       "      <td>POLYGON ((219000.000 616567.418, 219000.000 61...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>430</th>\n",
       "      <td>GM1966</td>\n",
       "      <td>Het Hogeland</td>\n",
       "      <td>NEE</td>\n",
       "      <td>414</td>\n",
       "      <td>5</td>\n",
       "      <td>99</td>\n",
       "      <td>47834</td>\n",
       "      <td>24052</td>\n",
       "      <td>23782</td>\n",
       "      <td>15</td>\n",
       "      <td>...</td>\n",
       "      <td>0</td>\n",
       "      <td>3</td>\n",
       "      <td>90308</td>\n",
       "      <td>48249</td>\n",
       "      <td>42059</td>\n",
       "      <td>2021GM1966</td>\n",
       "      <td>2021</td>\n",
       "      <td>321301.166576</td>\n",
       "      <td>4.875998e+08</td>\n",
       "      <td>MULTIPOLYGON (((217037.735 601967.991, 217043....</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>431</th>\n",
       "      <td>GM1969</td>\n",
       "      <td>Westerkwartier</td>\n",
       "      <td>NEE</td>\n",
       "      <td>476</td>\n",
       "      <td>5</td>\n",
       "      <td>176</td>\n",
       "      <td>63678</td>\n",
       "      <td>32034</td>\n",
       "      <td>31644</td>\n",
       "      <td>17</td>\n",
       "      <td>...</td>\n",
       "      <td>0</td>\n",
       "      <td>3</td>\n",
       "      <td>36887</td>\n",
       "      <td>36269</td>\n",
       "      <td>618</td>\n",
       "      <td>2021GM1969</td>\n",
       "      <td>2021</td>\n",
       "      <td>99030.762281</td>\n",
       "      <td>3.688457e+08</td>\n",
       "      <td>POLYGON ((215186.661 595044.495, 215190.788 59...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>432</th>\n",
       "      <td>GM1970</td>\n",
       "      <td>Noardeast-Fryslân</td>\n",
       "      <td>NEE</td>\n",
       "      <td>463</td>\n",
       "      <td>5</td>\n",
       "      <td>120</td>\n",
       "      <td>45481</td>\n",
       "      <td>22879</td>\n",
       "      <td>22602</td>\n",
       "      <td>17</td>\n",
       "      <td>...</td>\n",
       "      <td>0</td>\n",
       "      <td>2</td>\n",
       "      <td>51645</td>\n",
       "      <td>37783</td>\n",
       "      <td>13862</td>\n",
       "      <td>2021GM1970</td>\n",
       "      <td>2021</td>\n",
       "      <td>238426.959926</td>\n",
       "      <td>3.837930e+08</td>\n",
       "      <td>MULTIPOLYGON (((207769.575 603284.528, 207773....</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>433</th>\n",
       "      <td>GM1978</td>\n",
       "      <td>Molenlanden</td>\n",
       "      <td>NEE</td>\n",
       "      <td>393</td>\n",
       "      <td>5</td>\n",
       "      <td>243</td>\n",
       "      <td>44130</td>\n",
       "      <td>22317</td>\n",
       "      <td>21813</td>\n",
       "      <td>18</td>\n",
       "      <td>...</td>\n",
       "      <td>0</td>\n",
       "      <td>2</td>\n",
       "      <td>19158</td>\n",
       "      <td>18173</td>\n",
       "      <td>986</td>\n",
       "      <td>2021GM1978</td>\n",
       "      <td>2021</td>\n",
       "      <td>88570.376691</td>\n",
       "      <td>1.915841e+08</td>\n",
       "      <td>POLYGON ((123569.533 440132.167, 123576.153 44...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>434</th>\n",
       "      <td>GM1979</td>\n",
       "      <td>Eemsdelta</td>\n",
       "      <td>NEE</td>\n",
       "      <td>692</td>\n",
       "      <td>4</td>\n",
       "      <td>170</td>\n",
       "      <td>45587</td>\n",
       "      <td>22841</td>\n",
       "      <td>22746</td>\n",
       "      <td>14</td>\n",
       "      <td>...</td>\n",
       "      <td>2</td>\n",
       "      <td>5</td>\n",
       "      <td>36407</td>\n",
       "      <td>26789</td>\n",
       "      <td>9618</td>\n",
       "      <td>2021GM1979</td>\n",
       "      <td>2021</td>\n",
       "      <td>173966.493452</td>\n",
       "      <td>2.727771e+08</td>\n",
       "      <td>MULTIPOLYGON (((269190.000 594253.046, 269190....</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>435 rows × 38 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "    GM_CODE            GM_NAAM  H2O       OAD      STED  BEV_DICHTH  AANT_INW  \\\n",
       "0    GM0034             Almere   JA -99999999 -99999999   -99999999 -99999999   \n",
       "1    GM0050           Zeewolde   JA -99999999 -99999999   -99999999 -99999999   \n",
       "2    GM0060            Ameland   JA -99999999 -99999999   -99999999 -99999999   \n",
       "3    GM0072          Harlingen   JA -99999999 -99999999   -99999999 -99999999   \n",
       "4    GM0088    Schiermonnikoog   JA -99999999 -99999999   -99999999 -99999999   \n",
       "..      ...                ...  ...       ...       ...         ...       ...   \n",
       "430  GM1966       Het Hogeland  NEE       414         5          99     47834   \n",
       "431  GM1969     Westerkwartier  NEE       476         5         176     63678   \n",
       "432  GM1970  Noardeast-Fryslân  NEE       463         5         120     45481   \n",
       "433  GM1978        Molenlanden  NEE       393         5         243     44130   \n",
       "434  GM1979          Eemsdelta  NEE       692         4         170     45587   \n",
       "\n",
       "     AANT_MAN  AANT_VROUW  P_00_14_JR  ...  P_TURKIJE  P_OVER_NW   OPP_TOT  \\\n",
       "0   -99999999   -99999999   -99999999  ...  -99999999  -99999999 -99999999   \n",
       "1   -99999999   -99999999   -99999999  ...  -99999999  -99999999 -99999999   \n",
       "2   -99999999   -99999999   -99999999  ...  -99999999  -99999999 -99999999   \n",
       "3   -99999999   -99999999   -99999999  ...  -99999999  -99999999 -99999999   \n",
       "4   -99999999   -99999999   -99999999  ...  -99999999  -99999999 -99999999   \n",
       "..        ...         ...         ...  ...        ...        ...       ...   \n",
       "430     24052       23782          15  ...          0          3     90308   \n",
       "431     32034       31644          17  ...          0          3     36887   \n",
       "432     22879       22602          17  ...          0          2     51645   \n",
       "433     22317       21813          18  ...          0          2     19158   \n",
       "434     22841       22746          14  ...          2          5     36407   \n",
       "\n",
       "     OPP_LAND  OPP_WATER  JRSTATCODE  JAAR     Shape_Leng    Shape_Area  \\\n",
       "0   -99999999  -99999999  2021GM0034  2021  122665.358635  1.095623e+08   \n",
       "1   -99999999  -99999999  2021GM0050  2021   83290.773617  1.633050e+07   \n",
       "2   -99999999  -99999999  2021GM0060  2021  156406.894023  2.085914e+08   \n",
       "3   -99999999  -99999999  2021GM0072  2021  104274.683035  3.618323e+08   \n",
       "4   -99999999  -99999999  2021GM0088  2021  152568.858991  1.624101e+08   \n",
       "..        ...        ...         ...   ...            ...           ...   \n",
       "430     48249      42059  2021GM1966  2021  321301.166576  4.875998e+08   \n",
       "431     36269        618  2021GM1969  2021   99030.762281  3.688457e+08   \n",
       "432     37783      13862  2021GM1970  2021  238426.959926  3.837930e+08   \n",
       "433     18173        986  2021GM1978  2021   88570.376691  1.915841e+08   \n",
       "434     26789       9618  2021GM1979  2021  173966.493452  2.727771e+08   \n",
       "\n",
       "                                              geometry  \n",
       "0    MULTIPOLYGON (((150213.998 479503.726, 150087....  \n",
       "1    MULTIPOLYGON (((170588.413 486792.192, 170570....  \n",
       "2    POLYGON ((196000.000 610000.000, 196000.000 60...  \n",
       "3    MULTIPOLYGON (((158392.775 580357.500, 158387....  \n",
       "4    POLYGON ((219000.000 616567.418, 219000.000 61...  \n",
       "..                                                 ...  \n",
       "430  MULTIPOLYGON (((217037.735 601967.991, 217043....  \n",
       "431  POLYGON ((215186.661 595044.495, 215190.788 59...  \n",
       "432  MULTIPOLYGON (((207769.575 603284.528, 207773....  \n",
       "433  POLYGON ((123569.533 440132.167, 123576.153 44...  \n",
       "434  MULTIPOLYGON (((269190.000 594253.046, 269190....  \n",
       "\n",
       "[435 rows x 38 columns]"
      ]
     },
     "execution_count": 29,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "nl_map"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<AxesSubplot:>"
      ]
     },
     "execution_count": 3,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "[encoded data, 4792 characters]",
      "text/plain": [
       "<Figure size 720x720 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "import matplotlib.pyplot as plt\n",
    "\n",
    "fig, ax = plt.subplots(figsize = (10,10))\n",
    "nl_map.to_crs(epsg=4326).plot(ax=ax, color='lightgrey')\n",
    "df_geojson.plot(ax=ax)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "We hebben hier een probleem dat sommige punten de coördinaten 0,0 hebben, dit is niet iets wat we willen weergeven. Laten we eerst kijken waarom dit het geval is in de data voordat we het er helemaal uithalen."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "Stembureau                                                            32\n",
      "Adres                                                                   \n",
      "Locatie                                                             SB32\n",
      "description                               Stembureau Mobiel Stembureau 1\n",
      "Geldige stemmen                                                       99\n",
      "                                                       ...              \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                               NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                     NaN\n",
      "gewoon ge-DREVEN                                                     NaN\n",
      "VOOR Den Bosch Joep Gersjes                                          NaN\n",
      "geometry                                                     POINT (0 0)\n",
      "Name: 2520, Length: 973, dtype: object\n",
      "Stembureau                                                            33\n",
      "Adres                                                                   \n",
      "Locatie                                                             SB33\n",
      "description                               Stembureau Mobiel Stembureau 2\n",
      "Geldige stemmen                                                      115\n",
      "                                                       ...              \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                               NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                     NaN\n",
      "gewoon ge-DREVEN                                                     NaN\n",
      "VOOR Den Bosch Joep Gersjes                                          NaN\n",
      "geometry                                                     POINT (0 0)\n",
      "Name: 2521, Length: 973, dtype: object\n",
      "Stembureau                                                          157\n",
      "Adres                                                                  \n",
      "Locatie                                                           SB157\n",
      "description                               Stembureau Stembureau Stembus\n",
      "Geldige stemmen                                                      72\n",
      "                                                      ...              \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                              NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                    NaN\n",
      "gewoon ge-DREVEN                                                    NaN\n",
      "VOOR Den Bosch Joep Gersjes                                         NaN\n",
      "geometry                                                    POINT (0 0)\n",
      "Name: 2918, Length: 973, dtype: object\n",
      "Stembureau                                                                              171\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB171\n",
      "description                               Stembureau Stembureau Stembureau op locatie al...\n",
      "Geldige stemmen                                                                         174\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 3579, Length: 973, dtype: object\n",
      "Stembureau                                                                              172\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB172\n",
      "description                               Stembureau Stembureau Stembureau op locatie al...\n",
      "Geldige stemmen                                                                          66\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 3580, Length: 973, dtype: object\n",
      "Stembureau                                                                              173\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB173\n",
      "description                               Stembureau Stembureau Stembureau op locatie al...\n",
      "Geldige stemmen                                                                         162\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 3581, Length: 973, dtype: object\n",
      "Stembureau                                                                              174\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB174\n",
      "description                               Stembureau Stembureau Stembureau op locatie al...\n",
      "Geldige stemmen                                                                          65\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 3582, Length: 973, dtype: object\n",
      "Stembureau                                                                              175\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB175\n",
      "description                               Stembureau Stembureau Stembureau op locatie al...\n",
      "Geldige stemmen                                                                         121\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 3583, Length: 973, dtype: object\n",
      "Stembureau                                                                               39\n",
      "Adres                                                                                      \n",
      "Locatie                                                                                SB39\n",
      "description                               Stembureau Mobiel stembureau met beperkte toeg...\n",
      "Geldige stemmen                                                                          56\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 5494, Length: 973, dtype: object\n",
      "Stembureau                                                                               34\n",
      "Adres                                                                                      \n",
      "Locatie                                                                                SB34\n",
      "description                               Stembureau Stembureau Mobiel stembureau verzor...\n",
      "Geldige stemmen                                                                         119\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 5784, Length: 973, dtype: object\n",
      "Stembureau                                                                               35\n",
      "Adres                                                                                      \n",
      "Locatie                                                                                SB35\n",
      "description                               Stembureau Stembureau Mobiel stembureau verzor...\n",
      "Geldige stemmen                                                                         151\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 5785, Length: 973, dtype: object\n",
      "Stembureau                                                                   11\n",
      "Adres                                                                          \n",
      "Locatie                                                                    SB11\n",
      "description                               Stembureau Mobiel stembureau Ommedijk\n",
      "Geldige stemmen                                                              14\n",
      "                                                          ...                  \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                      NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                            NaN\n",
      "gewoon ge-DREVEN                                                            NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                 NaN\n",
      "geometry                                                            POINT (0 0)\n",
      "Name: 6260, Length: 973, dtype: object\n",
      "Stembureau                                                                               12\n",
      "Adres                                                                                      \n",
      "Locatie                                                                                SB12\n",
      "description                               Stembureau Mobiel stembureau Van Alphenstaete ...\n",
      "Geldige stemmen                                                                          68\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 6261, Length: 973, dtype: object\n",
      "Stembureau                                                          70\n",
      "Adres                                                                 \n",
      "Locatie                                                           SB70\n",
      "description                               Stembureau Mobiel stembureau\n",
      "Geldige stemmen                                                     34\n",
      "                                                      ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                   NaN\n",
      "gewoon ge-DREVEN                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                        NaN\n",
      "geometry                                                   POINT (0 0)\n",
      "Name: 6738, Length: 973, dtype: object\n",
      "Stembureau                                                          71\n",
      "Adres                                                                 \n",
      "Locatie                                                           SB71\n",
      "description                               Stembureau Mobiel stembureau\n",
      "Geldige stemmen                                                     43\n",
      "                                                      ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                   NaN\n",
      "gewoon ge-DREVEN                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                        NaN\n",
      "geometry                                                   POINT (0 0)\n",
      "Name: 6739, Length: 973, dtype: object\n",
      "Stembureau                                                                    699\n",
      "Adres                                                                            \n",
      "Locatie                                                                     SB699\n",
      "description                               Stembureau Stembureau Mobiel stembureau\n",
      "Geldige stemmen                                                                59\n",
      "                                                           ...                   \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                        NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                              NaN\n",
      "gewoon ge-DREVEN                                                              NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                   NaN\n",
      "geometry                                                              POINT (0 0)\n",
      "Name: 6863, Length: 973, dtype: object\n",
      "Stembureau                                                         32\n",
      "Adres                                                                \n",
      "Locatie                                                          SB32\n",
      "description                               Stembureau Mobielstembureau\n",
      "Geldige stemmen                                                    63\n",
      "                                                     ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                            NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                  NaN\n",
      "gewoon ge-DREVEN                                                  NaN\n",
      "VOOR Den Bosch Joep Gersjes                                       NaN\n",
      "geometry                                                  POINT (0 0)\n",
      "Name: 7348, Length: 973, dtype: object\n",
      "Stembureau                                                      90\n",
      "Adres                                                             \n",
      "Locatie                                                       SB90\n",
      "description                               Stembureau Roll and Vote\n",
      "Geldige stemmen                                                339\n",
      "                                                    ...           \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                         NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                               NaN\n",
      "gewoon ge-DREVEN                                               NaN\n",
      "VOOR Den Bosch Joep Gersjes                                    NaN\n",
      "geometry                                               POINT (0 0)\n",
      "Name: 7364, Length: 973, dtype: object\n",
      "Stembureau                                                          19\n",
      "Adres                                                                 \n",
      "Locatie                                                           SB19\n",
      "description                               Stembureau Mobiel stembureau\n",
      "Geldige stemmen                                                     77\n",
      "                                                      ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                   NaN\n",
      "gewoon ge-DREVEN                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                        NaN\n",
      "geometry                                                   POINT (0 0)\n",
      "Name: 7857, Length: 973, dtype: object\n",
      "Stembureau                                                                           1428\n",
      "Adres                                                                                    \n",
      "Locatie                                                                            SB1428\n",
      "description                               Stembureau Drive-thru parkeerplaats Rusheuvel 1\n",
      "Geldige stemmen                                                                       163\n",
      "                                                               ...                       \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                      NaN\n",
      "gewoon ge-DREVEN                                                                      NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                           NaN\n",
      "geometry                                                                      POINT (0 0)\n",
      "Name: 7912, Length: 973, dtype: object\n",
      "Stembureau                                                                           1437\n",
      "Adres                                                                                    \n",
      "Locatie                                                                            SB1437\n",
      "description                               Stembureau Drive-thru parkeerplaats Rusheuvel 2\n",
      "Geldige stemmen                                                                       239\n",
      "                                                               ...                       \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                      NaN\n",
      "gewoon ge-DREVEN                                                                      NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                           NaN\n",
      "geometry                                                                      POINT (0 0)\n",
      "Name: 7913, Length: 973, dtype: object\n",
      "Stembureau                                                                           1528\n",
      "Adres                                                                                    \n",
      "Locatie                                                                            SB1528\n",
      "description                               Stembureau Drive-thru parkeerplaats Rusheuvel 1\n",
      "Geldige stemmen                                                                       323\n",
      "                                                               ...                       \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                      NaN\n",
      "gewoon ge-DREVEN                                                                      NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                           NaN\n",
      "geometry                                                                      POINT (0 0)\n",
      "Name: 7923, Length: 973, dtype: object\n",
      "Stembureau                                                                           1537\n",
      "Adres                                                                                    \n",
      "Locatie                                                                            SB1537\n",
      "description                               Stembureau Drive-thru parkeerplaats Rusheuvel 2\n",
      "Geldige stemmen                                                                       208\n",
      "                                                               ...                       \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                      NaN\n",
      "gewoon ge-DREVEN                                                                      NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                           NaN\n",
      "geometry                                                                      POINT (0 0)\n",
      "Name: 7924, Length: 973, dtype: object\n",
      "Stembureau                                                        1541\n",
      "Adres                                                                 \n",
      "Locatie                                                         SB1541\n",
      "description                               Stembureau Mobiel stembureau\n",
      "Geldige stemmen                                                    125\n",
      "                                                      ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                   NaN\n",
      "gewoon ge-DREVEN                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                        NaN\n",
      "geometry                                                   POINT (0 0)\n",
      "Name: 7926, Length: 973, dtype: object\n",
      "Stembureau                                                            200\n",
      "Adres                                                                    \n",
      "Locatie                                                             SB200\n",
      "description                               Stembureau Mobiel stembureau Ma\n",
      "Geldige stemmen                                                        30\n",
      "                                                       ...               \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                      NaN\n",
      "gewoon ge-DREVEN                                                      NaN\n",
      "VOOR Den Bosch Joep Gersjes                                           NaN\n",
      "geometry                                                      POINT (0 0)\n",
      "Name: 7958, Length: 973, dtype: object\n",
      "Stembureau                                                            201\n",
      "Adres                                                                    \n",
      "Locatie                                                             SB201\n",
      "description                               Stembureau Mobiel stembureau Di\n",
      "Geldige stemmen                                                        30\n",
      "                                                       ...               \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                      NaN\n",
      "gewoon ge-DREVEN                                                      NaN\n",
      "VOOR Den Bosch Joep Gersjes                                           NaN\n",
      "geometry                                                      POINT (0 0)\n",
      "Name: 7959, Length: 973, dtype: object\n",
      "Stembureau                                                             202\n",
      "Adres                                                                     \n",
      "Locatie                                                              SB202\n",
      "description                               Stembureau Mobiel stembureau Woe\n",
      "Geldige stemmen                                                         44\n",
      "                                                        ...               \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                 NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                       NaN\n",
      "gewoon ge-DREVEN                                                       NaN\n",
      "VOOR Den Bosch Joep Gersjes                                            NaN\n",
      "geometry                                                       POINT (0 0)\n",
      "Name: 7960, Length: 973, dtype: object\n",
      "Stembureau                                                                               30\n",
      "Adres                                                                                      \n",
      "Locatie                                                                                SB30\n",
      "description                               Stembureau Stembureau voor de telling stembure...\n",
      "Geldige stemmen                                                                        2004\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 8108, Length: 973, dtype: object\n",
      "Stembureau                                                                               40\n",
      "Adres                                                                                      \n",
      "Locatie                                                                                SB40\n",
      "description                               Stembureau Stembureau voor de telling stembure...\n",
      "Geldige stemmen                                                                        2953\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 8109, Length: 973, dtype: object\n",
      "Stembureau                                                                             990\n",
      "Adres                                                                                     \n",
      "Locatie                                                                              SB990\n",
      "description                               Stembureau Mobiel stembureau (meerdere plaatsen)\n",
      "Geldige stemmen                                                                         47\n",
      "                                                                ...                       \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                 NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                       NaN\n",
      "gewoon ge-DREVEN                                                                       NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                            NaN\n",
      "geometry                                                                       POINT (0 0)\n",
      "Name: 8161, Length: 973, dtype: object\n",
      "Stembureau                                                                             991\n",
      "Adres                                                                                     \n",
      "Locatie                                                                              SB991\n",
      "description                               Stembureau Mobiel stembureau (meerdere plaatsen)\n",
      "Geldige stemmen                                                                         70\n",
      "                                                                ...                       \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                 NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                       NaN\n",
      "gewoon ge-DREVEN                                                                       NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                            NaN\n",
      "geometry                                                                       POINT (0 0)\n",
      "Name: 8162, Length: 973, dtype: object\n",
      "Stembureau                                                                             992\n",
      "Adres                                                                                     \n",
      "Locatie                                                                              SB992\n",
      "description                               Stembureau Mobiel stembureau (meerdere plaatsen)\n",
      "Geldige stemmen                                                                         39\n",
      "                                                                ...                       \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                 NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                       NaN\n",
      "gewoon ge-DREVEN                                                                       NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                            NaN\n",
      "geometry                                                                       POINT (0 0)\n",
      "Name: 8163, Length: 973, dtype: object\n",
      "Stembureau                                                                  17\n",
      "Adres                                                                         \n",
      "Locatie                                                                   SB17\n",
      "description                               Stembureau Mobiel Stembureau dinsdag\n",
      "Geldige stemmen                                                            115\n",
      "                                                          ...                 \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                     NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                           NaN\n",
      "gewoon ge-DREVEN                                                           NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                NaN\n",
      "geometry                                                           POINT (0 0)\n",
      "Name: 8318, Length: 973, dtype: object\n",
      "Stembureau                                                           228\n",
      "Adres                                                                   \n",
      "Locatie                                                            SB228\n",
      "description                               Stembureau Stembureau Drive-in\n",
      "Geldige stemmen                                                       80\n",
      "                                                       ...              \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                               NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                     NaN\n",
      "gewoon ge-DREVEN                                                     NaN\n",
      "VOOR Den Bosch Joep Gersjes                                          NaN\n",
      "geometry                                                     POINT (0 0)\n",
      "Name: 9093, Length: 973, dtype: object\n",
      "Stembureau                                                          30\n",
      "Adres                                                                 \n",
      "Locatie                                                           SB30\n",
      "description                               Stembureau Mobiel stembureau\n",
      "Geldige stemmen                                                     25\n",
      "                                                      ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                   NaN\n",
      "gewoon ge-DREVEN                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                        NaN\n",
      "geometry                                                   POINT (0 0)\n",
      "Name: 9151, Length: 973, dtype: object\n",
      "Stembureau                                                          31\n",
      "Adres                                                                 \n",
      "Locatie                                                           SB31\n",
      "description                               Stembureau Mobiel stembureau\n",
      "Geldige stemmen                                                      8\n",
      "                                                      ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                   NaN\n",
      "gewoon ge-DREVEN                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                        NaN\n",
      "geometry                                                   POINT (0 0)\n",
      "Name: 9152, Length: 973, dtype: object\n",
      "Stembureau                                                          32\n",
      "Adres                                                                 \n",
      "Locatie                                                           SB32\n",
      "description                               Stembureau Mobiel stembureau\n",
      "Geldige stemmen                                                     24\n",
      "                                                      ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                   NaN\n",
      "gewoon ge-DREVEN                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                        NaN\n",
      "geometry                                                   POINT (0 0)\n",
      "Name: 9153, Length: 973, dtype: object\n",
      "Stembureau                                                                 76\n",
      "Adres                                                                        \n",
      "Locatie                                                                  SB76\n",
      "description                               Stembureau Rondvaartboot Toerist VI\n",
      "Geldige stemmen                                                           148\n",
      "                                                         ...                 \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                    NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                          NaN\n",
      "gewoon ge-DREVEN                                                          NaN\n",
      "VOOR Den Bosch Joep Gersjes                                               NaN\n",
      "geometry                                                          POINT (0 0)\n",
      "Name: 9661, Length: 973, dtype: object\n",
      "Stembureau                                                                               68\n",
      "Adres                                                                                      \n",
      "Locatie                                                                                SB68\n",
      "description                               Stembureau Drive Inn (evenemententerrein Het L...\n",
      "Geldige stemmen                                                                         285\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 9853, Length: 973, dtype: object\n",
      "Stembureau                                                          14\n",
      "Adres                                                                 \n",
      "Locatie                                                           SB14\n",
      "description                               Stembureau Mobiel Stembureau\n",
      "Geldige stemmen                                                     24\n",
      "                                                      ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                   NaN\n",
      "gewoon ge-DREVEN                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                        NaN\n",
      "geometry                                                   POINT (0 0)\n",
      "Name: 10427, Length: 973, dtype: object\n",
      "Stembureau                                                          18\n",
      "Adres                                                                 \n",
      "Locatie                                                           SB18\n",
      "description                               Stembureau Mobiel stembureau\n",
      "Geldige stemmen                                                     50\n",
      "                                                      ...             \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                   NaN\n",
      "gewoon ge-DREVEN                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                        NaN\n",
      "geometry                                                   POINT (0 0)\n",
      "Name: 10431, Length: 973, dtype: object\n",
      "Stembureau                                                                          23\n",
      "Adres                                                                                 \n",
      "Locatie                                                                           SB23\n",
      "description                               Stembureau Stembureau Mobiel: Wkp Zout Veere\n",
      "Geldige stemmen                                                                     55\n",
      "                                                              ...                     \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                   NaN\n",
      "gewoon ge-DREVEN                                                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                        NaN\n",
      "geometry                                                                   POINT (0 0)\n",
      "Name: 10497, Length: 973, dtype: object\n",
      "Stembureau                                                                   24\n",
      "Adres                                                                          \n",
      "Locatie                                                                    SB24\n",
      "description                               Stembureau Stembureau Mobiel: Okp Dom\n",
      "Geldige stemmen                                                              35\n",
      "                                                          ...                  \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                      NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                            NaN\n",
      "gewoon ge-DREVEN                                                            NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                 NaN\n",
      "geometry                                                            POINT (0 0)\n",
      "Name: 10498, Length: 973, dtype: object\n",
      "Stembureau                                                            115\n",
      "Adres                                                                    \n",
      "Locatie                                                             SB115\n",
      "description                               Stembureau Tent Nijverheidslaan\n",
      "Geldige stemmen                                                       258\n",
      "                                                       ...               \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                      NaN\n",
      "gewoon ge-DREVEN                                                      NaN\n",
      "VOOR Den Bosch Joep Gersjes                                           NaN\n",
      "geometry                                                      POINT (0 0)\n",
      "Name: 10525, Length: 973, dtype: object\n",
      "Stembureau                                                            116\n",
      "Adres                                                                    \n",
      "Locatie                                                             SB116\n",
      "description                               Stembureau Tent Nijverheidslaan\n",
      "Geldige stemmen                                                       377\n",
      "                                                       ...               \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                      NaN\n",
      "gewoon ge-DREVEN                                                      NaN\n",
      "VOOR Den Bosch Joep Gersjes                                           NaN\n",
      "geometry                                                      POINT (0 0)\n",
      "Name: 10526, Length: 973, dtype: object\n",
      "Stembureau                                                                117\n",
      "Adres                                                                        \n",
      "Locatie                                                                 SB117\n",
      "description                               Stembureau Tent Peter Benenson park\n",
      "Geldige stemmen                                                           285\n",
      "                                                         ...                 \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                    NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                          NaN\n",
      "gewoon ge-DREVEN                                                          NaN\n",
      "VOOR Den Bosch Joep Gersjes                                               NaN\n",
      "geometry                                                          POINT (0 0)\n",
      "Name: 10527, Length: 973, dtype: object\n",
      "Stembureau                                                                118\n",
      "Adres                                                                        \n",
      "Locatie                                                                 SB118\n",
      "description                               Stembureau Tent Peter Benenson park\n",
      "Geldige stemmen                                                           329\n",
      "                                                         ...                 \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                    NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                          NaN\n",
      "gewoon ge-DREVEN                                                          NaN\n",
      "VOOR Den Bosch Joep Gersjes                                               NaN\n",
      "geometry                                                          POINT (0 0)\n",
      "Name: 10528, Length: 973, dtype: object\n",
      "Stembureau                                                                     310\n",
      "Adres                                                                             \n",
      "Locatie                                                                      SB310\n",
      "description                               Stembureau Mobiel Bijzonder stembureau 1\n",
      "Geldige stemmen                                                                 26\n",
      "                                                            ...                   \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                         NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                               NaN\n",
      "gewoon ge-DREVEN                                                               NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                    NaN\n",
      "geometry                                                               POINT (0 0)\n",
      "Name: 10623, Length: 973, dtype: object\n",
      "Stembureau                                                                     311\n",
      "Adres                                                                             \n",
      "Locatie                                                                      SB311\n",
      "description                               Stembureau Mobiel Bijzonder stembureau 2\n",
      "Geldige stemmen                                                                 55\n",
      "                                                            ...                   \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                         NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                               NaN\n",
      "gewoon ge-DREVEN                                                               NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                    NaN\n",
      "geometry                                                               POINT (0 0)\n",
      "Name: 10624, Length: 973, dtype: object\n",
      "Stembureau                                                            88\n",
      "Adres                                                                   \n",
      "Locatie                                                             SB88\n",
      "description                               Stembureau Mobiel stembureau 1\n",
      "Geldige stemmen                                                       78\n",
      "                                                       ...              \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                               NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                     NaN\n",
      "gewoon ge-DREVEN                                                     NaN\n",
      "VOOR Den Bosch Joep Gersjes                                          NaN\n",
      "geometry                                                     POINT (0 0)\n",
      "Name: 10894, Length: 973, dtype: object\n",
      "Stembureau                                                            89\n",
      "Adres                                                                   \n",
      "Locatie                                                             SB89\n",
      "description                               Stembureau Mobiel stembureau 2\n",
      "Geldige stemmen                                                       35\n",
      "                                                       ...              \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                               NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                     NaN\n",
      "gewoon ge-DREVEN                                                     NaN\n",
      "VOOR Den Bosch Joep Gersjes                                          NaN\n",
      "geometry                                                     POINT (0 0)\n",
      "Name: 10895, Length: 973, dtype: object\n",
      "Stembureau                                                                     31\n",
      "Adres                                                                            \n",
      "Locatie                                                                      SB31\n",
      "description                               Stembureau Stembureau Mobiel Stembureau\n",
      "Geldige stemmen                                                                32\n",
      "                                                           ...                   \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                        NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                              NaN\n",
      "gewoon ge-DREVEN                                                              NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                   NaN\n",
      "geometry                                                              POINT (0 0)\n",
      "Name: 11032, Length: 973, dtype: object\n",
      "Stembureau                                           0\n",
      "Adres                                                 \n",
      "Locatie                                            SB0\n",
      "description                               Stembureau -\n",
      "Geldige stemmen                                      0\n",
      "                                              ...     \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie             NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                   NaN\n",
      "gewoon ge-DREVEN                                   NaN\n",
      "VOOR Den Bosch Joep Gersjes                        NaN\n",
      "geometry                                   POINT (0 0)\n",
      "Name: 11101, Length: 973, dtype: object\n",
      "Stembureau                                                                              132\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB132\n",
      "description                               Stembureau Stembureau IJsselhallen drive thoug...\n",
      "Geldige stemmen                                                                          52\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 12038, Length: 973, dtype: object\n",
      "Stembureau                                                                              133\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB133\n",
      "description                               Stembureau Stembureau IJsselhallen drive throu...\n",
      "Geldige stemmen                                                                          48\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 12039, Length: 973, dtype: object\n",
      "Stembureau                                                                              232\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB232\n",
      "description                               Stembureau Stembureau IJsselhallen drive thoug...\n",
      "Geldige stemmen                                                                         113\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 12053, Length: 973, dtype: object\n",
      "Stembureau                                                                              233\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB233\n",
      "description                               Stembureau Stembureau IJsselhallen drive throu...\n",
      "Geldige stemmen                                                                          73\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        NaN\n",
      "gewoon ge-DREVEN                                                                        NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                             NaN\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 12054, Length: 973, dtype: object\n",
      "Stembureau                                                                      358\n",
      "Adres                                                                              \n",
      "Locatie                                                                       SB358\n",
      "description                               Stembureau Stembureau Mobiel stembureau 1\n",
      "Geldige stemmen                                                                  70\n",
      "                                                            ...                    \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                          NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                NaN\n",
      "gewoon ge-DREVEN                                                                NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                     NaN\n",
      "geometry                                                                POINT (0 0)\n",
      "Name: 12118, Length: 973, dtype: object\n",
      "Stembureau                                                                      359\n",
      "Adres                                                                              \n",
      "Locatie                                                                       SB359\n",
      "description                               Stembureau Stembureau Mobiel stembureau 2\n",
      "Geldige stemmen                                                                 169\n",
      "                                                            ...                    \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                          NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                NaN\n",
      "gewoon ge-DREVEN                                                                NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                     NaN\n",
      "geometry                                                                POINT (0 0)\n",
      "Name: 12119, Length: 973, dtype: object\n",
      "Stembureau                                                                      360\n",
      "Adres                                                                              \n",
      "Locatie                                                                       SB360\n",
      "description                               Stembureau Stembureau Mobiel stembureau 3\n",
      "Geldige stemmen                                                                  89\n",
      "                                                            ...                    \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                          NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                NaN\n",
      "gewoon ge-DREVEN                                                                NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                     NaN\n",
      "geometry                                                                POINT (0 0)\n",
      "Name: 12120, Length: 973, dtype: object\n",
      "Stembureau                                                                      361\n",
      "Adres                                                                              \n",
      "Locatie                                                                       SB361\n",
      "description                               Stembureau Stembureau Mobiel stembureau 4\n",
      "Geldige stemmen                                                                  36\n",
      "                                                            ...                    \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                          NaN\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                NaN\n",
      "gewoon ge-DREVEN                                                                NaN\n",
      "VOOR Den Bosch Joep Gersjes                                                     NaN\n",
      "geometry                                                                POINT (0 0)\n",
      "Name: 12121, Length: 973, dtype: object\n",
      "Stembureau                                                                              114\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB114\n",
      "description                               Stembureau Stembureau Mobiel stembureau (beper...\n",
      "Geldige stemmen                                                                         109\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                 11.0\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        8.0\n",
      "gewoon ge-DREVEN                                                                        0.0\n",
      "VOOR Den Bosch Joep Gersjes                                                             1.0\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 12504, Length: 973, dtype: object\n",
      "Stembureau                                                                              115\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB115\n",
      "description                               Stembureau Stembureau Mobiel Stembureau (beper...\n",
      "Geldige stemmen                                                                          80\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  9.0\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        5.0\n",
      "gewoon ge-DREVEN                                                                        0.0\n",
      "VOOR Den Bosch Joep Gersjes                                                             3.0\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 12505, Length: 973, dtype: object\n",
      "Stembureau                                                                              116\n",
      "Adres                                                                                      \n",
      "Locatie                                                                               SB116\n",
      "description                               Stembureau Stembureau Mobiel Stembureau (beper...\n",
      "Geldige stemmen                                                                         119\n",
      "                                                                ...                        \n",
      "\"Leefbaar 's-Hertogenbosch\" Paul Kagie                                                  3.0\n",
      "RAADSGROEPERING ''BOSCH-BELANG''                                                        3.0\n",
      "gewoon ge-DREVEN                                                                       20.0\n",
      "VOOR Den Bosch Joep Gersjes                                                             3.0\n",
      "geometry                                                                        POINT (0 0)\n",
      "Name: 12506, Length: 973, dtype: object\n"
     ]
    }
   ],
   "source": [
    "for index, row in df_geojson.iterrows():\n",
    "    if (row.geometry.centroid.x == 0.00000):\n",
    "        print(row)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Het zijn dus duidelijk allemaal mobiele stembureaus, die kunnen we in een aparte dataset houden voor later, voor nu zijn ze onbelangrijk voor de kaartweergave, laten we de dataset dus opsplitsen in drie dataframes, de originele, één frame zonder de mobiele stembureaus, en de mobiele stembureaus alleen."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [
    {
     "name": "stderr",
     "output_type": "stream",
     "text": [
      "/tmp/ipykernel_58008/291552514.py:3: UserWarning: Geometry is in a geographic CRS. Results from 'centroid' are likely incorrect. Use 'GeoSeries.to_crs()' to re-project geometries to a projected CRS before this operation.\n",
      "\n",
      "  mobiel_mask = df_geojson['geometry'].centroid.x == 0\n"
     ]
    },
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "2520\n",
      "2521\n",
      "2918\n",
      "3579\n",
      "3580\n",
      "3581\n",
      "3582\n",
      "3583\n",
      "5494\n",
      "5784\n",
      "5785\n",
      "6260\n",
      "6261\n",
      "6738\n",
      "6739\n",
      "6863\n",
      "7348\n",
      "7364\n",
      "7857\n",
      "7912\n",
      "7913\n",
      "7923\n",
      "7924\n",
      "7926\n",
      "7958\n",
      "7959\n",
      "7960\n",
      "8108\n",
      "8109\n",
      "8161\n",
      "8162\n",
      "8163\n",
      "8318\n",
      "9093\n",
      "9151\n",
      "9152\n",
      "9153\n",
      "9661\n",
      "9853\n",
      "10427\n",
      "10431\n",
      "10497\n",
      "10498\n",
      "10525\n",
      "10526\n",
      "10527\n",
      "10528\n",
      "10623\n",
      "10624\n",
      "10894\n",
      "10895\n",
      "11032\n",
      "11101\n",
      "12038\n",
      "12039\n",
      "12053\n",
      "12054\n",
      "12118\n",
      "12119\n",
      "12120\n",
      "12121\n",
      "12504\n",
      "12505\n",
      "12506\n"
     ]
    }
   ],
   "source": [
    "#de waarschuwing over de projectie die niet klopt kan genegeerd worden, we zoeken naar data die x = 0 is, de projectie gaat geen effect hebben op die data in Nederland\n",
    "#filter de data en print welke waardes 0 hebben op x\n",
    "mobiel_mask = df_geojson['geometry'].centroid.x == 0\n",
    "i = 0\n",
    "for item in mobiel_mask:\n",
    "    if item:\n",
    "        print(i)\n",
    "    i = i + 1"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "       Stembureau   Adres Locatie  \\\n",
      "0               1  9461BH     SB1   \n",
      "1               2  9461DA     SB2   \n",
      "2               3  9461JA     SB3   \n",
      "3               4  9451KD     SB4   \n",
      "4               6  9454PL     SB6   \n",
      "...           ...     ...     ...   \n",
      "12591         703  5391AR   SB703   \n",
      "12592         705  5391AR   SB705   \n",
      "12593         750  5382KE   SB750   \n",
      "12594         751  5382KE   SB751   \n",
      "12595         752  5283KE   SB752   \n",
      "\n",
      "                                             description  Geldige stemmen  \\\n",
      "0      Stembureau Gemeentehuis Gieten (postcode: 9461...              784   \n",
      "1              Stembureau OBS Gieten (postcode: 9461 DA)              562   \n",
      "2      Stembureau Zorgcentrum Dekelhem (postcode: 946...              566   \n",
      "3      Stembureau Ontmoetingscentrum Boerhorn Rolde (...             1495   \n",
      "4      Stembureau Dropshuis de Eekhof (postcode: 9454...              347   \n",
      "...                                                  ...              ...   \n",
      "12591  Stembureau Stembureau Gemeenschapshuis de Meen...              268   \n",
      "12592  Stembureau Stembureau Gemeenschapshuis De Meen...              398   \n",
      "12593  Stembureau Stembureau Gemeenschapshuis 't Zijl...              663   \n",
      "12594  Stembureau Stembureau Gemeenschapshuis 't Zijl...              170   \n",
      "12595  Stembureau Stembureau Gemeenschapshuis 't Zijl...              222   \n",
      "\n",
      "       Opgeroepen  Ongeldig  Blanco  Geldige stempassen  \\\n",
      "0            2780         3       3                 700   \n",
      "1            1396         0       0                 518   \n",
      "2            1409         2       2                 516   \n",
      "3            2209         2       4                1335   \n",
      "4             477         0       2                 298   \n",
      "...           ...       ...     ...                 ...   \n",
      "12591           0         0       1                 237   \n",
      "12592           0         1       0                 359   \n",
      "12593        2321         2       0                 552   \n",
      "12594           0         0       0                 151   \n",
      "12595           0         0       0                 193   \n",
      "\n",
      "       Geldige volmachtbewijzen  ...  \\\n",
      "0                            90  ...   \n",
      "1                            44  ...   \n",
      "2                            54  ...   \n",
      "3                           166  ...   \n",
      "4                            51  ...   \n",
      "...                         ...  ...   \n",
      "12591                        32  ...   \n",
      "12592                        40  ...   \n",
      "12593                       113  ...   \n",
      "12594                        19  ...   \n",
      "12595                        29  ...   \n",
      "\n",
      "       Nationale Bond tegen Overheidszaken - DH  Haags Belang  INL Den Haag  \\\n",
      "0                                           NaN           NaN           NaN   \n",
      "1                                           NaN           NaN           NaN   \n",
      "2                                           NaN           NaN           NaN   \n",
      "3                                           NaN           NaN           NaN   \n",
      "4                                           NaN           NaN           NaN   \n",
      "...                                         ...           ...           ...   \n",
      "12591                                       NaN           NaN           NaN   \n",
      "12592                                       NaN           NaN           NaN   \n",
      "12593                                       NaN           NaN           NaN   \n",
      "12594                                       NaN           NaN           NaN   \n",
      "12595                                       NaN           NaN           NaN   \n",
      "\n",
      "       Rosmalens Belang  De Bossche Groenen  \\\n",
      "0                   NaN                 NaN   \n",
      "1                   NaN                 NaN   \n",
      "2                   NaN                 NaN   \n",
      "3                   NaN                 NaN   \n",
      "4                   NaN                 NaN   \n",
      "...                 ...                 ...   \n",
      "12591             105.0                 2.0   \n",
      "12592             174.0                 6.0   \n",
      "12593              47.0                19.0   \n",
      "12594               8.0                11.0   \n",
      "12595              10.0                 2.0   \n",
      "\n",
      "       \"Leefbaar 's-Hertogenbosch\" Paul Kagie  \\\n",
      "0                                         NaN   \n",
      "1                                         NaN   \n",
      "2                                         NaN   \n",
      "3                                         NaN   \n",
      "4                                         NaN   \n",
      "...                                       ...   \n",
      "12591                                     6.0   \n",
      "12592                                     2.0   \n",
      "12593                                    53.0   \n",
      "12594                                    13.0   \n",
      "12595                                    22.0   \n",
      "\n",
      "       RAADSGROEPERING ''BOSCH-BELANG''  gewoon ge-DREVEN  \\\n",
      "0                                   NaN               NaN   \n",
      "1                                   NaN               NaN   \n",
      "2                                   NaN               NaN   \n",
      "3                                   NaN               NaN   \n",
      "4                                   NaN               NaN   \n",
      "...                                 ...               ...   \n",
      "12591                               0.0              33.0   \n",
      "12592                               3.0              31.0   \n",
      "12593                               2.0              62.0   \n",
      "12594                               1.0              22.0   \n",
      "12595                               2.0              28.0   \n",
      "\n",
      "       VOOR Den Bosch Joep Gersjes                  geometry  \n",
      "0                              NaN  POINT (6.75899 53.00524)  \n",
      "1                              NaN  POINT (6.75990 52.99975)  \n",
      "2                              NaN  POINT (6.76600 53.00494)  \n",
      "3                              NaN  POINT (6.64736 52.98281)  \n",
      "4                              NaN  POINT (6.60459 52.95269)  \n",
      "...                            ...                       ...  \n",
      "12591                          0.0  POINT (5.43290 51.72810)  \n",
      "12592                          2.0  POINT (5.43290 51.72810)  \n",
      "12593                          5.0  POINT (5.45919 51.70595)  \n",
      "12594                          1.0  POINT (5.45919 51.70595)  \n",
      "12595                          0.0  POINT (5.45919 51.70595)  \n",
      "\n",
      "[12532 rows x 973 columns]\n"
     ]
    }
   ],
   "source": [
    "df_geojson_clean = df_geojson[~mobiel_mask]\n",
    "df_geojson_mobiel = df_geojson[mobiel_mask]\n",
    "print(df_geojson_clean)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<AxesSubplot:>"
      ]
     },
     "execution_count": 7,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "[encoded data, 108492 characters]",
      "text/plain": [
       "<Figure size 720x720 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "fig, ax = plt.subplots(figsize = (10,10))\n",
    "nl_map.to_crs(epsg=4326).plot(ax=ax, color='lightgrey')\n",
    "df_geojson_clean.plot(ax=ax)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Nu we een mooie kaart hebben van nederland met de stemlokalen erop, kunnen we gaan kijken naar hoe dit verhoud met de bevolkingsdichtheid als eerste voorbeeld. De kaart is opgehaald van het CBS, eerst gaan we kijken hoe de kaart er op zichzelf met dezelfde projectie uitziet."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<AxesSubplot:>"
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "[encoded data, 43592 characters]",
      "text/plain": [
       "<Figure size 432x288 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "nl_map_cbs = gpd.read_file(r'../data/shape/Netherlands_shapefile/CBS_vk500_2020_v1.shp')\n",
    "nl_map_cbs.to_crs(epsg=4326).plot()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Het verwerken van de 500m bij 500m vierkanten kaar duurde heel lang (langer dan een half uur) op de laptop, en is dus niet ideaal tenzij we dit niveau van detail écht nodig hebben. Er is namelijk nog een andere kaart met dezelfde gegevens beschikbaar, maar met een grid van 500 bij 500 meter in plaats van 100 bij 100. Laten we dus kijken hoe vaak een stemlokaal dichterbij dan 100 meter van de dichtstbijzijnde andere is. De makkelijkste manier om dat te doen zonder alle punten met alle andere te vergelijken (heel veel moeite), is een extra dataframe maken als een kopie, alle indexen 1 opschuiven (want alle stemlokalen zijn al in een volgorde van clustering), en dan de laagste afstand bekijken."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "11165         0.002608\n",
      "1021          0.004853\n",
      "3196          0.004875\n",
      "1923          2.693202\n",
      "3757          3.609362\n",
      "             ...      \n",
      "7444     253385.654588\n",
      "9711     263408.187856\n",
      "4392     266925.200994\n",
      "9297     271954.076837\n",
      "0                  NaN\n",
      "Name: distance, Length: 11670, dtype: float64\n"
     ]
    }
   ],
   "source": [
    "df_shifted = df_geojson_clean.to_crs('EPSG:28992')\n",
    "\n",
    "df_shifted['geometry (shifted)'] = df_shifted['geometry'].shift(periods=1)\n",
    "df_shifted['distance'] = df_shifted['geometry'].distance(df_shifted['geometry (shifted)'])\n",
    "df_shifted.sort_values(['distance'], inplace=True, ascending=True)\n",
    "zero_mask_booth = df_shifted['distance'] == 0.000000\n",
    "df_shifted = df_shifted[~zero_mask_booth]\n",
    "print(df_shifted['distance'])"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "We kunnen dus vaststellen dat afstanden van onder de 500 meter waarschijnlijk zeldzaam zijn, en we verder kunnen gaan met de 500 meter bij 500 meter kaart. Laten we nu dus een projectie proberen te maken met de bevolkingsdichtheid erop om het te vergelijken met de stemlokalen en hun posities en clustering."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "['c28992r500', 'INWONER', 'MAN', 'VROUW', 'INW_014', 'INW_1524', 'INW_2544', 'INW_4564', 'INW_65PL', 'P_NL_ACHTG', 'P_WE_MIG_A', 'P_NW_MIG_A', 'AANTAL_HH', 'TOTHH_EENP', 'TOTHH_MPZK', 'HH_EENOUD', 'HH_TWEEOUD', 'GEM_HH_GR', 'WONING', 'WONVOOR45', 'WON_4564', 'WON_6574', 'WON_7584', 'WON_8594', 'WON_9504', 'WON_0514', 'WON_1524', 'WON_MRGEZ', 'P_KOOPWON', 'P_HUURWON', 'WON_HCORP', 'WON_NBEW', 'WOZWONING', 'UITKMINAOW', 'OAD', 'STED', 'geometry']\n"
     ]
    },
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>c28992r500</th>\n",
       "      <th>INWONER</th>\n",
       "      <th>geometry</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>267</th>\n",
       "      <td>E2050N6110</td>\n",
       "      <td>5</td>\n",
       "      <td>POLYGON ((205000.000 611500.000, 205500.000 61...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>269</th>\n",
       "      <td>E2060N6110</td>\n",
       "      <td>15</td>\n",
       "      <td>POLYGON ((206000.000 611500.000, 206500.000 61...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>292</th>\n",
       "      <td>E2055N6105</td>\n",
       "      <td>20</td>\n",
       "      <td>POLYGON ((205500.000 611000.000, 206000.000 61...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>293</th>\n",
       "      <td>E2060N6105</td>\n",
       "      <td>185</td>\n",
       "      <td>POLYGON ((206000.000 611000.000, 206500.000 61...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>294</th>\n",
       "      <td>E2065N6105</td>\n",
       "      <td>340</td>\n",
       "      <td>POLYGON ((206500.000 611000.000, 207000.000 61...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>...</th>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "      <td>...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>151071</th>\n",
       "      <td>E1970N3075</td>\n",
       "      <td>10</td>\n",
       "      <td>POLYGON ((197000.000 308000.000, 197500.000 30...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>151073</th>\n",
       "      <td>E1980N3075</td>\n",
       "      <td>90</td>\n",
       "      <td>POLYGON ((198000.000 308000.000, 198500.000 30...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>151074</th>\n",
       "      <td>E1985N3075</td>\n",
       "      <td>15</td>\n",
       "      <td>POLYGON ((198500.000 308000.000, 199000.000 30...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>151100</th>\n",
       "      <td>E1980N3070</td>\n",
       "      <td>5</td>\n",
       "      <td>POLYGON ((198000.000 307500.000, 198500.000 30...</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>151106</th>\n",
       "      <td>E1920N3065</td>\n",
       "      <td>20</td>\n",
       "      <td>POLYGON ((192000.000 307000.000, 192500.000 30...</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "<p>70656 rows × 3 columns</p>\n",
       "</div>"
      ],
      "text/plain": [
       "        c28992r500  INWONER                                           geometry\n",
       "267     E2050N6110        5  POLYGON ((205000.000 611500.000, 205500.000 61...\n",
       "269     E2060N6110       15  POLYGON ((206000.000 611500.000, 206500.000 61...\n",
       "292     E2055N6105       20  POLYGON ((205500.000 611000.000, 206000.000 61...\n",
       "293     E2060N6105      185  POLYGON ((206000.000 611000.000, 206500.000 61...\n",
       "294     E2065N6105      340  POLYGON ((206500.000 611000.000, 207000.000 61...\n",
       "...            ...      ...                                                ...\n",
       "151071  E1970N3075       10  POLYGON ((197000.000 308000.000, 197500.000 30...\n",
       "151073  E1980N3075       90  POLYGON ((198000.000 308000.000, 198500.000 30...\n",
       "151074  E1985N3075       15  POLYGON ((198500.000 308000.000, 199000.000 30...\n",
       "151100  E1980N3070        5  POLYGON ((198000.000 307500.000, 198500.000 30...\n",
       "151106  E1920N3065       20  POLYGON ((192000.000 307000.000, 192500.000 30...\n",
       "\n",
       "[70656 rows x 3 columns]"
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "print(list(nl_map_cbs))\n",
    "nl_map_dst = nl_map_cbs.drop(columns=['MAN', 'VROUW', 'INW_014', 'INW_1524', 'INW_2544', 'INW_4564', 'INW_65PL', 'P_NL_ACHTG', 'P_WE_MIG_A', 'P_NW_MIG_A', 'AANTAL_HH', 'TOTHH_EENP', 'TOTHH_MPZK', 'HH_EENOUD', 'HH_TWEEOUD', 'GEM_HH_GR', 'WONING', 'WONVOOR45', 'WON_4564', 'WON_6574', 'WON_7584', 'WON_8594', 'WON_9504', 'WON_0514', 'WON_1524', 'WON_MRGEZ', 'P_KOOPWON', 'P_HUURWON', 'WON_HCORP', 'WON_NBEW', 'WOZWONING', 'UITKMINAOW', 'OAD', 'STED'])\n",
    "zero_mask_pop = nl_map_dst['INWONER'] == -99997\n",
    "nl_map_dst = nl_map_dst[~zero_mask_pop]\n",
    "nl_map_dst"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 47,
   "metadata": {},
   "outputs": [],
   "source": [
    "import folium\n",
    "from folium import plugins\n",
    "\n",
    "map = folium.Map(location = [52.155, 5.3875], zoom_start = 9, tiles=\"cartodbdark_matter\", prefer_canvas=True)\n",
    "\n",
    "nl_map_dst.to_crs(epsg=4326)\n",
    "#Make sure the index is a string so folium can read it correctly as a key.\n",
    "nl_map_dst['c28992r500'] = nl_map_dst['c28992r500'].apply(lambda x: str(x))\n",
    "\n",
    "folium.Choropleth(\n",
    "    geo_data = nl_map_dst,\n",
    "    name=\"Bevolkingsdichtheid\",\n",
    "    data = nl_map_dst,\n",
    "    columns = [\"c28992r500\", \"INWONER\"],\n",
    "    key_on = 'feature.properties.c28992r500',\n",
    "    fill_color = 'RdPu',\n",
    "    nan_fill_color= 'white',\n",
    "    fill_opacity = 0.7,\n",
    "    nan_fill_opacity = 0.7,\n",
    "    line_opacity = 0,\n",
    "    legend_name = 'Bevolkingsdichtheid',\n",
    "    smooth_factor = 1.0,\n",
    "    show=False\n",
    ").add_to(map)\n",
    "\n",
    "# Renders the map to an HTML file and displays it in an embed.\n",
    "def embed_map(m):\n",
    "    #from IPython.display import IFrame\n",
    "    m.save('index.html')\n",
    "    #return IFrame('index.html', width='100%', height='750px')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 48,
   "metadata": {},
   "outputs": [],
   "source": [
    "df_geojson_clean_hmp = [[point.xy[1][0], point.xy[0][0]] for point in df_geojson_clean.geometry]\n",
    "\n",
    "plugins.HeatMap(df_geojson_clean_hmp, name=\"Stemlokalen Heatmap\").add_to(map)\n",
    "\n",
    "folium.LayerControl().add_to(map)\n",
    "\n",
    "\n",
    "\n",
    "embed_map(map)\n",
    "\n",
    "\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>c28992r500</th>\n",
       "      <th>INWONER</th>\n",
       "      <th>geometry</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>267</th>\n",
       "      <td>E2050N6110</td>\n",
       "      <td>5</td>\n",
       "      <td>POINT (205250.000 611250.000)</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>269</th>\n",
       "      <td>E2060N6110</td>\n",
       "      <td>15</td>\n",
       "      <td>POINT (206250.000 611250.000)</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>292</th>\n",
       "      <td>E2055N6105</td>\n",
       "      <td>20</td>\n",
       "      <td>POINT (205750.000 610750.000)</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>293</th>\n",
       "      <td>E2060N6105</td>\n",
       "      <td>185</td>\n",
       "      <td>POINT (206250.000 610750.000)</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>294</th>\n",
       "      <td>E2065N6105</td>\n",
       "      <td>340</td>\n",
       "      <td>POINT (206750.000 610750.000)</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "     c28992r500  INWONER                       geometry\n",
       "267  E2050N6110        5  POINT (205250.000 611250.000)\n",
       "269  E2060N6110       15  POINT (206250.000 611250.000)\n",
       "292  E2055N6105       20  POINT (205750.000 610750.000)\n",
       "293  E2060N6105      185  POINT (206250.000 610750.000)\n",
       "294  E2065N6105      340  POINT (206750.000 610750.000)"
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "nl_map_dst_points = nl_map_dst\n",
    "nl_map_dst_points['geometry'] = nl_map_dst_points['geometry'].centroid\n",
    "nl_map_dst_points.head()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 17,
   "metadata": {
    "scrolled": false
   },
   "outputs": [
    {
     "data": {
      "text/plain": [
       "<AxesSubplot:ylabel='Frequency'>"
      ]
     },
     "execution_count": 17,
     "metadata": {},
     "output_type": "execute_result"
    },
    {
     "data": {
      "image/png": "[encoded data, 11952 characters]",
      "text/plain": [
       "<Figure size 1080x1080 with 1 Axes>"
      ]
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "import numpy as np\n",
    "\n",
    "from scipy.spatial import cKDTree\n",
    "from shapely.geometry import Point\n",
    "\n",
    "def ckdnearest(gdA, gdB):\n",
    "\n",
    "    nA = np.array(list(gdA.geometry.apply(lambda x: (x.x, x.y))))\n",
    "    nB = np.array(list(gdB.geometry.apply(lambda x: (x.x, x.y))))\n",
    "    btree = cKDTree(nB)\n",
    "    dist, idx = btree.query(nA, k=1)\n",
    "    gdB_nearest = gdB.iloc[idx].drop(columns=\"geometry\").reset_index(drop=True)\n",
    "    gdf = pd.concat(\n",
    "        [\n",
    "            gdA.reset_index(drop=True),\n",
    "            gdB_nearest,\n",
    "            pd.Series(dist, name='dist')\n",
    "        ], \n",
    "        axis=1)\n",
    "\n",
    "    return gdf\n",
    "\n",
    "#error bar is +- sqrt(250²*2)m ≈ +-353.553390593m\n",
    "df_nearest = ckdnearest(nl_map_dst_points.to_crs(epsg=28992), df_geojson_clean.to_crs(epsg=28992))\n",
    "\n",
    "#ax = df_nearest.plot.bar(x='INWONER', y='dist')\n",
    "df_nearest['dist'].plot(kind=\"hist\", bins=40, weights=df_nearest['INWONER'], figsize=(15,15))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [
    {
     "ename": "SyntaxError",
     "evalue": "invalid syntax (745234620.py, line 3)",
     "output_type": "error",
     "traceback": [
      "\u001b[0;36m  Input \u001b[0;32mIn [13]\u001b[0;36m\u001b[0m\n\u001b[0;31m    dfwims.\u001b[0m\n\u001b[0m           ^\u001b[0m\n\u001b[0;31mSyntaxError\u001b[0m\u001b[0;31m:\u001b[0m invalid syntax\n"
     ]
    }
   ],
   "source": [
    "df_wims = pd.read_csv(r'../data/wims.csv')\n",
    "print(df_wims)\n",
    "dfwims."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "#de eerste vijf rijen zijn meta-data en kunnen we gerust weghalen voor nu \n",
    "df_gr_gr = pd.read_csv(r'../data/stemmen/01_Groningen/osv4-3_telling_gr2022_groningen.csv', skiprows=5, header=None, delimiter=';')\n",
    "print(df_gr_gr)\n"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "De data is heel gecompliceerd, dus we moeten het bruikbaar maken in pandas. Met hoe de data eruit ziet in een CSV in libre office willen we een constructie maken van de verschillende onderdelen. We hebben de data van de stemlokalen apart al, die kunnen we dus negeren. We willen de data van de lijsten apart hebben. "
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "TODO:mobiele stemlokalen eruit filteren die NIET 0,0 zijn\n",
    "TODO:gooi dichtheid data van niet verkiezingsgemeente weg\n",
    "TODO:datastandaard duitse verkiezingen stemlokaalafstand opzoeken"
   ]
  }
 ],
 "metadata": {
  "interpreter": {
   "hash": "3d1ccb9efb47efc90847d5703ae4e5663eea6663e461c6dfd943b50a653adc65"
  },
  "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.10.4"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
