The results of the French legislative elections are given by constituency, but what is the distribution of votes by municipality? A geographical visualization in the form of a choropleth map makes it possible to study it.
It is also an opportunity to illustrate some of the many possibilities of the visualization library Folium
Each constituency map provides the results of the candidates in the second round of the legislative elections:
- The percentages of the candidates are divided into 6 levels of color to highlight the municipalities where they have their highest or lowest results.
- The selector on the right side of the map allows you to choose the visualization of each candidate.
- The results by municipality are accessible by hovering over the municipality.
- The color palettes are chosen for their readability and do not represent the political orientation of the candidates.
The map of the 12th constituency of Nord, below, is an example.
The Python source code, the data sources used, and information about the tools used are available on a Github repository (in French).
Limitations
- For obvious reasons, as there are no municipalities for French citizens living around the Globe, the constituencies of French citizens living abroad (department code ZZ) are not displayed.
- Due to the lack of cartographic data, the results of the following overseas territories are NOT represented:
- New Caledonia (department code ZZ of the file from data.gouv.fr)
- French Polynesia (department code ZP)
- Saint Pierre and Miquelon (department code ZS)
- Wallis and Futuna (department code ZW)
- Saint Martin / Saint Barthélemy (department code ZX)
The cartographic information for the municipalities comes from the excellent website of Grégoire David. However, some mergers of municipalities have taken place since his work and 2022. In this case, the municipalities are not represented and appear in white.
Results
-
- Ain, Allier, Ardèche, Cantal, Drôme, Haute-Loire, Haute-Savoie, Isère, Loire, Puy-de-Dôme, Rhône, Savoie
-
- Aisne, Nord, Oise, Pas-de-Calais, Somme
Auvergne-Rhône-Alpes
Ain
Allier
Ardèche
Cantal
Drôme
Haute-Loire
Haute-Savoie
Isère
Loire
Puy-de-Dôme
Rhône
Savoie
Bourgogne-Franche-Comté
Côte-d’Or
Doubs
Haute-Saône
Jura
Nièvre
Saône-et-Loire
Territoire de Belfort
Yonne
Bretagne
Côtes-d’Armor
Finistère
Ille-et-Vilaine
Morbihan
Centre-Val de Loire
Cher
Eure-et-Loir
Indre
Indre-et-Loire
Loir-et-Cher
Loiret
Corse
Corse-du-Sud
Haute-Corse
Grand Est
Ardennes
Aube
Bas-Rhin
Haut-Rhin
Haute-Marne
Marne
Meurthe-et-Moselle
Meuse
Moselle
Vosges
Guadeloupe
Guadeloupe
Guyane
Guyane
Hauts-de-France
Aisne
Nord
Oise
Pas-de-Calais
Somme
La Réunion
La Réunion
Martinique
Martinique
Mayotte
Mayotte
Normandie
Calvados
Eure
Manche
Orne
Seine-Maritime
Nouvelle-Aquitaine
Charente
Charente-Maritime
Corrèze
Creuse
- Constituencies: 01
Deux-Sèvres
Dordogne
Gironde
Haute-Vienne
Landes
Lot-et-Garonne
Pyrénées-Atlantiques
Vienne
Occitanie
Ariège
Aude
Aveyron
Gard
Gers
Haute-Garonne
Hautes-Pyrénées
Hérault
Lot
Lozère
- Constituencies: 01