Here is an example of a
treemap plot using
matplotlib and the
The data comes from the open data of the Communauté d’Agglomération Pau-Pyrénées.
The idea is the following :
- The area of each square is the surface area of the towns
- The color scale is over the population in 2011
Source code :
Here is an other version where Pau is present. Nevertheless, I draw a white square background because the population of Pau is huge compared to other towns and thus I did not include it in the color scale.