diff --git a/tests/data/notebooks/inputs/ipynb_py/World population.ipynb b/tests/data/notebooks/inputs/ipynb_py/World population.ipynb
deleted file mode 100644
index a8bae7d5a..000000000
--- a/tests/data/notebooks/inputs/ipynb_py/World population.ipynb
+++ /dev/null
@@ -1,1475 +0,0 @@
-{
- "cells": [
- {
- "cell_type": "markdown",
- "metadata": {},
- "source": [
- "# A quick insight at world population\n",
- "\n",
- "## Collecting population data\n",
- "\n",
- "In the below we retrieve population data from the\n",
- "[World Bank](http://www.worldbank.org/)\n",
- "using the [wbdata](https://github.com/OliverSherouse/wbdata) python package"
- ]
- },
- {
- "cell_type": "code",
- "execution_count": 1,
- "metadata": {},
- "outputs": [],
- "source": [
- "import pandas as pd\n",
- "import wbdata as wb\n",
- "\n",
- "pd.options.display.max_rows = 6\n",
- "pd.options.display.max_columns = 20"
- ]
- },
- {
- "cell_type": "markdown",
- "metadata": {},
- "source": [
- "Corresponding indicator is found using search method - or, directly,\n",
- "the World Bank site."
- ]
- },
- {
- "cell_type": "code",
- "execution_count": 2,
- "metadata": {},
- "outputs": [
- {
- "name": "stdout",
- "output_type": "stream",
- "text": [
- "SP.POP.TOTL\tPopulation, total\n"
- ]
- }
- ],
- "source": [
- "wb.search_indicators('Population, total') # SP.POP.TOTL\n",
- "# wb.search_indicators('area')\n",
- "# => https://data.worldbank.org/indicator is easier to use"
- ]
- },
- {
- "cell_type": "markdown",
- "metadata": {},
- "source": [
- "Now we download the population data"
- ]
- },
- {
- "cell_type": "code",
- "execution_count": 3,
- "metadata": {},
- "outputs": [
- {
- "data": {
- "text/html": [
- "
\n",
- "\n",
- "
\n",
- " \n",
- " \n",
- " | \n",
- " | \n",
- " Population, total | \n",
- " Surface area (sq. km) | \n",
- " Land area (sq. km) | \n",
- " Arable land (% of land area) | \n",
- "
\n",
- " \n",
- " country | \n",
- " date | \n",
- " | \n",
- " | \n",
- " | \n",
- " | \n",
- "
\n",
- " \n",
- " \n",
- " \n",
- " Afghanistan | \n",
- " 1960-01-01 | \n",
- " 8996351.0 | \n",
- " NaN | \n",
- " NaN | \n",
- " NaN | \n",
- "
\n",
- " \n",
- " 1961-01-01 | \n",
- " 9166764.0 | \n",
- " 652860.0 | \n",
- " 652860.0 | \n",
- " 11.717673 | \n",
- "
\n",
- " \n",
- " 1962-01-01 | \n",
- " 9345868.0 | \n",
- " 652860.0 | \n",
- " 652860.0 | \n",
- " 11.794259 | \n",
- "
\n",
- " \n",
- " ... | \n",
- " ... | \n",
- " ... | \n",
- " ... | \n",
- " ... | \n",
- " ... | \n",
- "
\n",
- " \n",
- " Zimbabwe | \n",
- " 2015-01-01 | \n",
- " 15777451.0 | \n",
- " 390760.0 | \n",
- " 386850.0 | \n",
- " 10.339925 | \n",
- "
\n",
- " \n",
- " 2016-01-01 | \n",
- " 16150362.0 | \n",
- " 390760.0 | \n",
- " 386850.0 | \n",
- " NaN | \n",
- "
\n",
- " \n",
- " 2017-01-01 | \n",
- " 16529904.0 | \n",
- " 390760.0 | \n",
- " 386850.0 | \n",
- " NaN | \n",
- "
\n",
- " \n",
- "
\n",
- "
15312 rows × 4 columns
\n",
- "
"
- ],
- "text/plain": [
- " Population, total Surface area (sq. km) \\\n",
- "country date \n",
- "Afghanistan 1960-01-01 8996351.0 NaN \n",
- " 1961-01-01 9166764.0 652860.0 \n",
- " 1962-01-01 9345868.0 652860.0 \n",
- "... ... ... \n",
- "Zimbabwe 2015-01-01 15777451.0 390760.0 \n",
- " 2016-01-01 16150362.0 390760.0 \n",
- " 2017-01-01 16529904.0 390760.0 \n",
- "\n",
- " Land area (sq. km) Arable land (% of land area) \n",
- "country date \n",
- "Afghanistan 1960-01-01 NaN NaN \n",
- " 1961-01-01 652860.0 11.717673 \n",
- " 1962-01-01 652860.0 11.794259 \n",
- "... ... ... \n",
- "Zimbabwe 2015-01-01 386850.0 10.339925 \n",
- " 2016-01-01 386850.0 NaN \n",
- " 2017-01-01 386850.0 NaN \n",
- "\n",
- "[15312 rows x 4 columns]"
- ]
- },
- "execution_count": 3,
- "metadata": {},
- "output_type": "execute_result"
- }
- ],
- "source": [
- "indicators = {'SP.POP.TOTL': 'Population, total',\n",
- " 'AG.SRF.TOTL.K2': 'Surface area (sq. km)',\n",
- " 'AG.LND.TOTL.K2': 'Land area (sq. km)',\n",
- " 'AG.LND.ARBL.ZS': 'Arable land (% of land area)'}\n",
- "data = wb.get_dataframe(indicators, convert_date=True).sort_index()\n",
- "data"
- ]
- },
- {
- "cell_type": "markdown",
- "metadata": {},
- "source": [
- "World is one of the countries"
- ]
- },
- {
- "cell_type": "code",
- "execution_count": 4,
- "metadata": {},
- "outputs": [
- {
- "data": {
- "text/html": [
- "\n",
- "\n",
- "
\n",
- " \n",
- " \n",
- " | \n",
- " Population, total | \n",
- " Surface area (sq. km) | \n",
- " Land area (sq. km) | \n",
- " Arable land (% of land area) | \n",
- "
\n",
- " \n",
- " date | \n",
- " | \n",
- " | \n",
- " | \n",
- " | \n",
- "
\n",
- " \n",
- " \n",
- " \n",
- " 1960-01-01 | \n",
- " 3.032160e+09 | \n",
- " NaN | \n",
- " NaN | \n",
- " NaN | \n",
- "
\n",
- " \n",
- " 1961-01-01 | \n",
- " 3.073369e+09 | \n",
- " 134043190.4 | \n",
- " 129721455.4 | \n",
- " 9.693086 | \n",
- "
\n",
- " \n",
- " 1962-01-01 | \n",
- " 3.126510e+09 | \n",
- " 134043190.4 | \n",
- " 129721435.4 | \n",
- " 9.726105 | \n",
- "
\n",
- " \n",
- " ... | \n",
- " ... | \n",
- " ... | \n",
- " ... | \n",
- " ... | \n",
- "
\n",
- " \n",
- " 2015-01-01 | \n",
- " 7.357559e+09 | \n",
- " 134325130.2 | \n",
- " 129732901.8 | \n",
- " 10.991288 | \n",
- "
\n",
- " \n",
- " 2016-01-01 | \n",
- " 7.444157e+09 | \n",
- " 134325130.2 | \n",
- " 129733172.7 | \n",
- " NaN | \n",
- "
\n",
- " \n",
- " 2017-01-01 | \n",
- " 7.530360e+09 | \n",
- " 134325130.2 | \n",
- " 129733172.7 | \n",
- " NaN | \n",
- "
\n",
- " \n",
- "
\n",
- "
58 rows × 4 columns
\n",
- "
"
- ],
- "text/plain": [
- " Population, total Surface area (sq. km) Land area (sq. km) \\\n",
- "date \n",
- "1960-01-01 3.032160e+09 NaN NaN \n",
- "1961-01-01 3.073369e+09 134043190.4 129721455.4 \n",
- "1962-01-01 3.126510e+09 134043190.4 129721435.4 \n",
- "... ... ... ... \n",
- "2015-01-01 7.357559e+09 134325130.2 129732901.8 \n",
- "2016-01-01 7.444157e+09 134325130.2 129733172.7 \n",
- "2017-01-01 7.530360e+09 134325130.2 129733172.7 \n",
- "\n",
- " Arable land (% of land area) \n",
- "date \n",
- "1960-01-01 NaN \n",
- "1961-01-01 9.693086 \n",
- "1962-01-01 9.726105 \n",
- "... ... \n",
- "2015-01-01 10.991288 \n",
- "2016-01-01 NaN \n",
- "2017-01-01 NaN \n",
- "\n",
- "[58 rows x 4 columns]"
- ]
- },
- "execution_count": 4,
- "metadata": {},
- "output_type": "execute_result"
- }
- ],
- "source": [
- "data.loc['World']"
- ]
- },
- {
- "cell_type": "markdown",
- "metadata": {},
- "source": [
- "Can we classify over continents?"
- ]
- },
- {
- "cell_type": "code",
- "execution_count": 5,
- "metadata": {},
- "outputs": [
- {
- "data": {
- "text/plain": [
- "Index(['Iran, Islamic Rep.', 'Congo, Dem. Rep.', 'Germany', 'Vietnam',\n",
- " 'Egypt, Arab Rep.', 'Central Europe and the Baltics', 'Philippines',\n",
- " 'Ethiopia', 'Japan', 'Mexico', 'Russian Federation', 'Bangladesh',\n",
- " 'Nigeria', 'Pakistan', 'Brazil', 'Indonesia', 'United States',\n",
- " 'Euro area', 'North America',\n",
- " 'Middle East & North Africa (IDA & IBRD countries)',\n",
- " 'Middle East & North Africa (excluding high income)', 'Arab World',\n",
- " 'Europe & Central Asia (excluding high income)',\n",
- " 'Middle East & North Africa',\n",
- " 'Europe & Central Asia (IDA & IBRD countries)',\n",
- " 'Fragile and conflict affected situations', 'European Union',\n",
- " 'IDA blend', 'Latin America & Caribbean (excluding high income)',\n",
- " 'Latin America & the Caribbean (IDA & IBRD countries)',\n",
- " 'Latin America & Caribbean', 'Low income',\n",
- " 'Heavily indebted poor countries (HIPC)', 'Pre-demographic dividend',\n",
- " 'Europe & Central Asia', 'Least developed countries: UN classification',\n",
- " 'Sub-Saharan Africa (excluding high income)',\n",
- " 'Sub-Saharan Africa (IDA & IBRD countries)', 'Sub-Saharan Africa',\n",
- " 'IDA only', 'Post-demographic dividend', 'High income', 'OECD members',\n",
- " 'India', 'China', 'IDA total', 'South Asia (IDA & IBRD)', 'South Asia',\n",
- " 'East Asia & Pacific (IDA & IBRD countries)',\n",
- " 'East Asia & Pacific (excluding high income)',\n",
- " 'Late-demographic dividend', 'East Asia & Pacific',\n",
- " 'Upper middle income', 'Lower middle income',\n",
- " 'Early-demographic dividend', 'IBRD only', 'Middle income',\n",
- " 'Low & middle income', 'IDA & IBRD total', 'World'],\n",
- " dtype='object', name='country')"
- ]
- },
- "execution_count": 5,
- "metadata": {},
- "output_type": "execute_result"
- }
- ],
- "source": [
- "data.loc[(slice(None), '2017-01-01'), :]['Population, total'].dropna(\n",
- ").sort_values().tail(60).index.get_level_values('country')"
- ]
- },
- {
- "cell_type": "markdown",
- "metadata": {},
- "source": [
- "Extract zones manually (in order of increasing population)"
- ]
- },
- {
- "cell_type": "code",
- "execution_count": 6,
- "metadata": {},
- "outputs": [],
- "source": [
- "zones = ['North America', 'Middle East & North Africa',\n",
- " 'Latin America & Caribbean', 'Europe & Central Asia',\n",
- " 'Sub-Saharan Africa', 'South Asia',\n",
- " 'East Asia & Pacific'][::-1]"
- ]
- },
- {
- "cell_type": "markdown",
- "metadata": {},
- "source": [
- "And extract population information (and check total is right)"
- ]
- },
- {
- "cell_type": "code",
- "execution_count": 21,
- "metadata": {},
- "outputs": [],
- "source": [
- "population = data.loc[zones]['Population, total'].swaplevel().unstack()\n",
- "population = population[zones]\n",
- "assert all(data.loc['World']['Population, total'] == population.sum(axis=1))"
- ]
- },
- {
- "cell_type": "markdown",
- "metadata": {},
- "source": [
- "## Stacked area plot with matplotlib"
- ]
- },
- {
- "cell_type": "code",
- "execution_count": 22,
- "metadata": {},
- "outputs": [],
- "source": [
- "import matplotlib.pyplot as plt"
- ]
- },
- {
- "cell_type": "code",
- "execution_count": 23,
- "metadata": {},
- "outputs": [
- {
- "data": {
- "text/plain": [
- "