Initial commit : add environment initialization

parent 99722c5d
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Incidence de la varicelle\n",
"## Récupération des données: \n",
"Initialisation de l'environnement de développement."
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"%matplotlib inline\n",
"import matplotlib.pyplot as plt\n",
"import pandas as pd\n",
"import isoweek\n",
"\n",
"#variables d'import des données :\n",
"data_url = \"http://www.sentiweb.fr/datasets/incidence-PAY-3.csv\"\n",
"data_local = \"incidence-PAY-3.csv\"\n",
"\n",
"import os\n",
"import urllib.request\n",
"#Test de présence des données : \n",
"if os.path.exists(data_local):\n",
" raw_data = pd.read_csv(data_local, skiprows=1)\n",
" print(\"Local File Selected\")\n",
"else :\n",
" urllib.request.urlretrieve(data_url, data_data)\n",
" raw_data = pd.read_csv(data_url, skiprows=1)\n",
"\n",
"#Contient les données local ou provenant de l'url ci-dessus.\n",
"raw_data"
]
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"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.6.4"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
{
"cells": [],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"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.6.3"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment