diff --git a/module3/exo2/exercice.ipynb b/module3/exo2/exercice.ipynb index 0bbbe371b01e359e381e43239412d77bf53fb1fb..687a96ef61f68732734f1259b329be2eac4dbe40 100644 --- a/module3/exo2/exercice.ipynb +++ b/module3/exo2/exercice.ipynb @@ -1,5 +1,64 @@ { - "cells": [], + "cells": [ + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Analyse sur l'incidence de la varicelle" + ] + }, + { + "cell_type": "code", + "execution_count": 1, + "metadata": {}, + "outputs": [], + "source": [ + "%matplotlib inline\n", + "import pandas as pd\n", + "import matplotlib.pyplot as plt\n", + "import isoweek" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Phase 1 : chargement des données\n", + "On télécharge d'[ici](https://www.sentiweb.fr/france/fr/?page=table).\n", + "J'ai choisi de ne prendre que sentinelle (sans IQVIA), au niveau national, et de renommer ce \"inc-7-PAY.csv\" en \"varicelle.csv\"." + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [ + "url = 'https://www.sentiweb.fr/datasets/all/inc-7-PAY.csv'" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [ + "try:\n", + " raw_data = pd.read_csv('./incidence_gripale.csv',index=True)\n", + "except:\n", + " raw_data = pd.read_csv(data_url, skiprows=1)\n", + " raw_data.to_csv('./incidence_gripale.csv')\n", + "raw_data.head()" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [] + } + ], "metadata": { "kernelspec": { "display_name": "Python 3", @@ -16,10 +75,9 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.6.3" + "version": "3.6.4" } }, "nbformat": 4, "nbformat_minor": 2 } -