{ "cells": [ { "cell_type": "code", "execution_count": 28, "metadata": { "collapsed": false }, "outputs": [], "source": [ "import pandas as pd\n", "from opytex import texenv\n", "%matplotlib inline" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "# Informations sur le devoir" ] }, { "cell_type": "code", "execution_count": 29, "metadata": { "collapsed": false }, "outputs": [ { "data": { "text/plain": [ "{'classe': '313', 'date': '25 septembre 2015', 'titre': 'DS 1'}" ] }, "execution_count": 29, "metadata": {}, "output_type": "execute_result" } ], "source": [ "ds_name = \"DS_15_09_25\"\n", "classe = \"313\"\n", "\n", "latex_info = {}\n", "latex_info['titre'] = \"DS 1\" \n", "latex_info['classe'] = classe\n", "latex_info['date'] = \"25 septembre 2015\"\n", "latex_info" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "# Import et premiers traitements" ] }, { "cell_type": "code", "execution_count": 30, "metadata": { "collapsed": false, "scrolled": true }, "outputs": [], "source": [ "notes = pd.ExcelFile(\"./../../../\"+classe+\".xlsx\")\n", "notes.sheet_names\n", "notes = notes.parse(ds_name)" ] }, { "cell_type": "code", "execution_count": 31, "metadata": { "collapsed": false }, "outputs": [ { "data": { "text/plain": [ "Index([ 'DS_15_09_25', 'numero sujet',\n", " 'Presentation', 'Exercice 1',\n", " 1, 2,\n", " 'Exercice 2', '1 (Division)',\n", " '2.a (Division)', '2.b (PGCD)',\n", " 'Exercice 3', '1 (Vrai Faux)',\n", " '2 (Proba)', '3 (Proba)',\n", " 'Exercice 4', '1 (Modélisation)',\n", " '1 (Explication)', '2 (Vérification) – bonus !'],\n", " dtype='object')" ] }, "execution_count": 31, "metadata": {}, "output_type": "execute_result" } ], "source": [ "notes.index" ] }, { "cell_type": "code", "execution_count": 32, "metadata": { "collapsed": true }, "outputs": [], "source": [ "notes = notes.T" ] }, { "cell_type": "code", "execution_count": 33, "metadata": { "collapsed": false }, "outputs": [], "source": [ "#notes = notes.drop('av_arrondi', axis=1)\n", "notes = notes.drop('numero sujet', axis=1)" ] }, { "cell_type": "code", "execution_count": 34, "metadata": { "collapsed": false }, "outputs": [ { "data": { "text/html": [ "
\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
DS_15_09_25PresentationExercice 112Exercice 21 (Division)2.a (Division)2.b (PGCD)Exercice 31 (Vrai Faux)2 (Proba)3 (Proba)Exercice 41 (Modélisation)1 (Explication)2 (Vérification) – bonus !
ABDOU Mariam18.013.0334.6666672225.5000003334.000000333
ABTOIHI SAID Yasmina10.011.5123.6666670133.8333331320.00000000NaN
AHAMED Anssuifidine7.013.0332.0000000NaN21.0000002NaNNaN0.00000000NaN
AHAMED Issihaka15.013.0335.6666671333.1666671312.333333221
AHMED ABDOU El-Karim5.011.5211.0000000011.50000030NaN0.000000NaNNaNNaN
ANDILI Chayhati14.012.0226.0000003324.8333333320.000000NaNNaNNaN
ANDJILANE Rachma8.013.0331.0000000013.1666671310.000000NaNNaNNaN
ANLI Koudoussia13.511.0115.0000001234.8333333231.500000NaN13
ATTOUMANI Hanissa12.513.0334.6666671323.0000002300.8333331NaN1
BACO ABDALLAH Moustadirane10.510.5013.6666670135.0000002330.50000001NaN
BINALI Maoulida13.513.0334.0000003305.5000003330.00000000NaN
BOINA Ainati12.012.5323.0000000035.5000003330.00000000NaN
BOINA HASSANI Nahimi4.512.0221.0000000010.5000001NaNNaN0.00000000NaN
DAOUD El-Farouk12.013.0332.0000000024.1666673311.833333211
DJADAR Ifrah12.513.0333.6666670134.8333333320.000000NaNNaNNaN
HALIBOU Nafilati8.510.0003.0000000034.5000001330.00000000NaN
HALIDI Tomsoyère0.0NaN0.0NaNNaN0.000000NaNNaNNaN0.000000NaNNaNNaN0.000000NaNNaNNaN
HOUMADI Himida3.010.0000.0000000001.6666672100.333333001
HOUMADI Antufati6.510.0002.6666670122.8333333110.00000000NaN
HOUMADI ABDALLAH Abdallah13.013.0333.6666672215.0000002330.50000010NaN
IBRAHIM Laoura4.510.0002.0000000020.5000001001.00000011NaN
MALIDE ABDOU Nasser12.012.5323.0000000034.1666673311.50000021NaN
MALIDE Younes19.513.0337.0000003334.5000001334.000000333
MOENY MOKO Nadjma7.512.5322.6666670121.5000003000.00000000NaN
MOUGNIDAHO Nouriana13.012.5323.0000000035.5000003331.00000011NaN
MOURTADJOU El-Fazar20.013.0337.0000003335.5000003333.500000323
SAID Chamsoudine13.013.0334.000000NaN324.8333333230.00000000NaN
YANCOUB Toufa13.512.5326.0000003322.5000001301.666667112
YOUSSOUF Asma10.510.00NaN4.00000033NaN5.5000003330.00000000NaN
\n", "
" ], "text/plain": [ " DS_15_09_25 Presentation Exercice 1 1 2 \\\n", "ABDOU Mariam 18.0 1 3.0 3 3 \n", "ABTOIHI SAID Yasmina 10.0 1 1.5 1 2 \n", "AHAMED Anssuifidine 7.0 1 3.0 3 3 \n", "AHAMED Issihaka 15.0 1 3.0 3 3 \n", "AHMED ABDOU El-Karim 5.0 1 1.5 2 1 \n", "ANDILI Chayhati 14.0 1 2.0 2 2 \n", "ANDJILANE Rachma 8.0 1 3.0 3 3 \n", "ANLI Koudoussia 13.5 1 1.0 1 1 \n", "ATTOUMANI Hanissa 12.5 1 3.0 3 3 \n", "BACO ABDALLAH Moustadirane 10.5 1 0.5 0 1 \n", "BINALI Maoulida 13.5 1 3.0 3 3 \n", "BOINA Ainati 12.0 1 2.5 3 2 \n", "BOINA HASSANI Nahimi 4.5 1 2.0 2 2 \n", "DAOUD El-Farouk 12.0 1 3.0 3 3 \n", "DJADAR Ifrah 12.5 1 3.0 3 3 \n", "HALIBOU Nafilati 8.5 1 0.0 0 0 \n", "HALIDI Tomsoyère 0.0 NaN 0.0 NaN NaN \n", "HOUMADI Himida 3.0 1 0.0 0 0 \n", "HOUMADI Antufati 6.5 1 0.0 0 0 \n", "HOUMADI ABDALLAH Abdallah 13.0 1 3.0 3 3 \n", "IBRAHIM Laoura 4.5 1 0.0 0 0 \n", "MALIDE ABDOU Nasser 12.0 1 2.5 3 2 \n", "MALIDE Younes 19.5 1 3.0 3 3 \n", "MOENY MOKO Nadjma 7.5 1 2.5 3 2 \n", "MOUGNIDAHO Nouriana 13.0 1 2.5 3 2 \n", "MOURTADJOU El-Fazar 20.0 1 3.0 3 3 \n", "SAID Chamsoudine 13.0 1 3.0 3 3 \n", "YANCOUB Toufa 13.5 1 2.5 3 2 \n", "YOUSSOUF Asma 10.5 1 0.0 0 NaN \n", "\n", " Exercice 2 1 (Division) 2.a (Division) \\\n", "ABDOU Mariam 4.666667 2 2 \n", "ABTOIHI SAID Yasmina 3.666667 0 1 \n", "AHAMED Anssuifidine 2.000000 0 NaN \n", "AHAMED Issihaka 5.666667 1 3 \n", "AHMED ABDOU El-Karim 1.000000 0 0 \n", "ANDILI Chayhati 6.000000 3 3 \n", "ANDJILANE Rachma 1.000000 0 0 \n", "ANLI Koudoussia 5.000000 1 2 \n", "ATTOUMANI Hanissa 4.666667 1 3 \n", "BACO ABDALLAH Moustadirane 3.666667 0 1 \n", "BINALI Maoulida 4.000000 3 3 \n", "BOINA Ainati 3.000000 0 0 \n", "BOINA HASSANI Nahimi 1.000000 0 0 \n", "DAOUD El-Farouk 2.000000 0 0 \n", "DJADAR Ifrah 3.666667 0 1 \n", "HALIBOU Nafilati 3.000000 0 0 \n", "HALIDI Tomsoyère 0.000000 NaN NaN \n", "HOUMADI Himida 0.000000 0 0 \n", "HOUMADI Antufati 2.666667 0 1 \n", "HOUMADI ABDALLAH Abdallah 3.666667 2 2 \n", "IBRAHIM Laoura 2.000000 0 0 \n", "MALIDE ABDOU Nasser 3.000000 0 0 \n", "MALIDE Younes 7.000000 3 3 \n", "MOENY MOKO Nadjma 2.666667 0 1 \n", "MOUGNIDAHO Nouriana 3.000000 0 0 \n", "MOURTADJOU El-Fazar 7.000000 3 3 \n", "SAID Chamsoudine 4.000000 NaN 3 \n", "YANCOUB Toufa 6.000000 3 3 \n", "YOUSSOUF Asma 4.000000 3 3 \n", "\n", " 2.b (PGCD) Exercice 3 1 (Vrai Faux) 2 (Proba) \\\n", "ABDOU Mariam 2 5.500000 3 3 \n", "ABTOIHI SAID Yasmina 3 3.833333 1 3 \n", "AHAMED Anssuifidine 2 1.000000 2 NaN \n", "AHAMED Issihaka 3 3.166667 1 3 \n", "AHMED ABDOU El-Karim 1 1.500000 3 0 \n", "ANDILI Chayhati 2 4.833333 3 3 \n", "ANDJILANE Rachma 1 3.166667 1 3 \n", "ANLI Koudoussia 3 4.833333 3 2 \n", "ATTOUMANI Hanissa 2 3.000000 2 3 \n", "BACO ABDALLAH Moustadirane 3 5.000000 2 3 \n", "BINALI Maoulida 0 5.500000 3 3 \n", "BOINA Ainati 3 5.500000 3 3 \n", "BOINA HASSANI Nahimi 1 0.500000 1 NaN \n", "DAOUD El-Farouk 2 4.166667 3 3 \n", "DJADAR Ifrah 3 4.833333 3 3 \n", "HALIBOU Nafilati 3 4.500000 1 3 \n", "HALIDI Tomsoyère NaN 0.000000 NaN NaN \n", "HOUMADI Himida 0 1.666667 2 1 \n", "HOUMADI Antufati 2 2.833333 3 1 \n", "HOUMADI ABDALLAH Abdallah 1 5.000000 2 3 \n", "IBRAHIM Laoura 2 0.500000 1 0 \n", "MALIDE ABDOU Nasser 3 4.166667 3 3 \n", "MALIDE Younes 3 4.500000 1 3 \n", "MOENY MOKO Nadjma 2 1.500000 3 0 \n", "MOUGNIDAHO Nouriana 3 5.500000 3 3 \n", "MOURTADJOU El-Fazar 3 5.500000 3 3 \n", "SAID Chamsoudine 2 4.833333 3 2 \n", "YANCOUB Toufa 2 2.500000 1 3 \n", "YOUSSOUF Asma NaN 5.500000 3 3 \n", "\n", " 3 (Proba) Exercice 4 1 (Modélisation) \\\n", "ABDOU Mariam 3 4.000000 3 \n", "ABTOIHI SAID Yasmina 2 0.000000 0 \n", "AHAMED Anssuifidine NaN 0.000000 0 \n", "AHAMED Issihaka 1 2.333333 2 \n", "AHMED ABDOU El-Karim NaN 0.000000 NaN \n", "ANDILI Chayhati 2 0.000000 NaN \n", "ANDJILANE Rachma 1 0.000000 NaN \n", "ANLI Koudoussia 3 1.500000 NaN \n", "ATTOUMANI Hanissa 0 0.833333 1 \n", "BACO ABDALLAH Moustadirane 3 0.500000 0 \n", "BINALI Maoulida 3 0.000000 0 \n", "BOINA Ainati 3 0.000000 0 \n", "BOINA HASSANI Nahimi NaN 0.000000 0 \n", "DAOUD El-Farouk 1 1.833333 2 \n", "DJADAR Ifrah 2 0.000000 NaN \n", "HALIBOU Nafilati 3 0.000000 0 \n", "HALIDI Tomsoyère NaN 0.000000 NaN \n", "HOUMADI Himida 0 0.333333 0 \n", "HOUMADI Antufati 1 0.000000 0 \n", "HOUMADI ABDALLAH Abdallah 3 0.500000 1 \n", "IBRAHIM Laoura 0 1.000000 1 \n", "MALIDE ABDOU Nasser 1 1.500000 2 \n", "MALIDE Younes 3 4.000000 3 \n", "MOENY MOKO Nadjma 0 0.000000 0 \n", "MOUGNIDAHO Nouriana 3 1.000000 1 \n", "MOURTADJOU El-Fazar 3 3.500000 3 \n", "SAID Chamsoudine 3 0.000000 0 \n", "YANCOUB Toufa 0 1.666667 1 \n", "YOUSSOUF Asma 3 0.000000 0 \n", "\n", " 1 (Explication) 2 (Vérification) – bonus ! \n", "ABDOU Mariam 3 3 \n", "ABTOIHI SAID Yasmina 0 NaN \n", "AHAMED Anssuifidine 0 NaN \n", "AHAMED Issihaka 2 1 \n", "AHMED ABDOU El-Karim NaN NaN \n", "ANDILI Chayhati NaN NaN \n", "ANDJILANE Rachma NaN NaN \n", "ANLI Koudoussia 1 3 \n", "ATTOUMANI Hanissa NaN 1 \n", "BACO ABDALLAH Moustadirane 1 NaN \n", "BINALI Maoulida 0 NaN \n", "BOINA Ainati 0 NaN \n", "BOINA HASSANI Nahimi 0 NaN \n", "DAOUD El-Farouk 1 1 \n", "DJADAR Ifrah NaN NaN \n", "HALIBOU Nafilati 0 NaN \n", "HALIDI Tomsoyère NaN NaN \n", "HOUMADI Himida 0 1 \n", "HOUMADI Antufati 0 NaN \n", "HOUMADI ABDALLAH Abdallah 0 NaN \n", "IBRAHIM Laoura 1 NaN \n", "MALIDE ABDOU Nasser 1 NaN \n", "MALIDE Younes 3 3 \n", "MOENY MOKO Nadjma 0 NaN \n", "MOUGNIDAHO Nouriana 1 NaN \n", "MOURTADJOU El-Fazar 2 3 \n", "SAID Chamsoudine 0 NaN \n", "YANCOUB Toufa 1 2 \n", "YOUSSOUF Asma 0 NaN " ] }, "execution_count": 34, "metadata": {}, "output_type": "execute_result" } ], "source": [ "barem = notes[:1]\n", "notes = notes[1:]\n", "notes" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Supression des notes inutiles " ] }, { "cell_type": "code", "execution_count": 35, "metadata": { "collapsed": false }, "outputs": [], "source": [ "notes = notes[notes[ds_name].notnull()]\n", "#notes = notes[notes[ds_name] != 'abs']" ] }, { "cell_type": "code", "execution_count": 36, "metadata": { "collapsed": false }, "outputs": [], "source": [ "notes = notes.astype(float)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Traitement des notes" ] }, { "cell_type": "code", "execution_count": 37, "metadata": { "collapsed": false, "scrolled": true }, "outputs": [ { "data": { "text/plain": [ "Index([ 'DS_15_09_25', 'Presentation',\n", " 'Exercice 1', 1,\n", " 2, 'Exercice 2',\n", " '1 (Division)', '2.a (Division)',\n", " '2.b (PGCD)', 'Exercice 3',\n", " '1 (Vrai Faux)', '2 (Proba)',\n", " '3 (Proba)', 'Exercice 4',\n", " '1 (Modélisation)', '1 (Explication)',\n", " '2 (Vérification) – bonus !'],\n", " dtype='object')" ] }, "execution_count": 37, "metadata": {}, "output_type": "execute_result" } ], "source": [ "notes.T.index" ] }, { "cell_type": "code", "execution_count": 38, "metadata": { "collapsed": false }, "outputs": [], "source": [ "list_exo = [\"Exercice 1\", \"Exercice 2\", \"Exercice 3\",\"Exercice 4\"]" ] }, { "cell_type": "code", "execution_count": 39, "metadata": { "collapsed": false }, "outputs": [], "source": [ "notes[list_exo] = notes[list_exo].applymap(lambda x:round(x,2))\n", "#notes[list_exo]" ] }, { "cell_type": "code", "execution_count": 40, "metadata": { "collapsed": false, "scrolled": true }, "outputs": [ { "data": { "text/plain": [ "[1,\n", " 2,\n", " '1 (Division)',\n", " '2.a (Division)',\n", " '2.b (PGCD)',\n", " '1 (Vrai Faux)',\n", " '2 (Proba)',\n", " '3 (Proba)',\n", " '1 (Modélisation)',\n", " '1 (Explication)',\n", " '2 (Vérification) – bonus\\xa0!']" ] }, "execution_count": 40, "metadata": {}, "output_type": "execute_result" } ], "source": [ "item_avec_note = list_exo + [ds_name, \"Presentation\"]\n", "sous_exo = [i for i in notes.T.index if i not in item_avec_note]\n", "sous_exo" ] }, { "cell_type": "code", "execution_count": 41, "metadata": { "collapsed": false }, "outputs": [], "source": [ "def toRepVal(val):\n", " if pd.isnull(val):\n", " return \"\\\\NoRep\"\n", " elif val == 0:\n", " return \"\\\\RepZ\"\n", " elif val == 1:\n", " return \"\\\\RepU\"\n", " elif val == 2:\n", " return \"\\\\RepD\"\n", " elif val == 3:\n", " return \"\\\\RepT\"\n", " else:\n", " return val" ] }, { "cell_type": "code", "execution_count": 42, "metadata": { "collapsed": false }, "outputs": [], "source": [ "notes[item_avec_note] = notes[item_avec_note].fillna(\".\")\n", "#notes" ] }, { "cell_type": "code", "execution_count": 43, "metadata": { "collapsed": true }, "outputs": [], "source": [ "eleves = notes.copy()\n", "eleves[sous_exo] = notes[sous_exo].applymap(toRepVal)" ] }, { "cell_type": "code", "execution_count": 44, "metadata": { "collapsed": false }, "outputs": [ { "data": { "text/plain": [ "17" ] }, "execution_count": 44, "metadata": {}, "output_type": "execute_result" } ], "source": [ "len(notes.T.index)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "# Preparation du fichier .tex" ] }, { "cell_type": "code", "execution_count": 45, "metadata": { "collapsed": false }, "outputs": [], "source": [ "bilan = texenv.get_template(\"tpl_bilan.tex\")\n", "with open(\"./bilan313.tex\",\"w\") as f:\n", " f.write(bilan.render(eleves = eleves, barem = barem, ds_name = ds_name, latex_info = latex_info, nbr_questions = len(barem.T)))" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "# Un peu de statistiques" ] }, { "cell_type": "code", "execution_count": 24, "metadata": { "collapsed": false }, "outputs": [ { "data": { "text/plain": [ "count 28.000000\n", "mean 10.517857\n", "std 4.637772\n", "min 0.000000\n", "25% 7.375000\n", "50% 12.000000\n", "75% 13.125000\n", "max 20.000000\n", "Name: DS_15_09_25, dtype: float64" ] }, "execution_count": 24, "metadata": {}, "output_type": "execute_result" } ], "source": [ "notes[ds_name].describe()" ] }, { "cell_type": "code", "execution_count": 25, "metadata": { "collapsed": false }, "outputs": [ { "data": { "text/plain": [ "" ] }, "execution_count": 25, "metadata": {}, "output_type": "execute_result" }, { "data": { "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXUAAAEACAYAAABMEua6AAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAEW1JREFUeJzt3W2MXOV5xvHrwnboC4lWgOpSbGvbAm1BkdaNZIxoYKy+\nyHZVp5VQC1KULJWKFdVKRL+kjaKSD1H7iYrSEHAFxE5bhaCgOk5kGlC04yJVMnmxeatpsRpLNgTT\nBkwAKxImdz/MsXc8npcz3ufsOfPM/yetPM+cZ8559t6z9x5fO8d2RAgAkIeL6l4AACAdmjoAZISm\nDgAZoakDQEZo6gCQEZo6AGRkaFO3/TO2D9g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3o0R8SFJW9T569mH615Q\nTqLzzgHO26W5X9KvSJqT9ENJd9e7nMli+xJJj0n6VES81b2tzPlZdVMvc/MSxhARPyz+/F9J/6pO\nxIWlOWH7FyXJ9hWSXqt5PRMtIl6LgqQHxTlamu1V6jT0f4qIPcXTY52fVTf1szcv2X6fOjcv7a34\nmNmy/XO23188/nlJvyfpueGvQgl7JX28ePxxSXuGzMUIReM544/EOVqKO7fZPiTpPyPinq5NY52f\nlb9P3fYWSfdo8ealv630gBmz/cvqXJ1LnRvH/oV6jsf2VyTdLOlydfLJv5b0dUmPSlon6aikP46I\nk3WtcZL0qeddklrqRC8h6QeStve7yxznsv1bkv5d0rNajFj+StLTGuP85OYjAMgI/50dAGSEpg4A\nGaGpA0BGaOoAkBGaOgBkhKYOABmhqQNARmjqAJCR/wf112yIH8O2rgAAAABJRU5ErkJggg==\n", "text/plain": [ "" ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "notes_seules = notes[ds_name]\n", "notes_seules.hist(bins = (notes_seules.max() - notes_seules.min())*2)" ] }, { "cell_type": "code", "execution_count": 26, "metadata": { "collapsed": false }, "outputs": [], "source": [ "notes_questions = notes[sous_exo]\n", "notes_analysis = notes_questions.describe()" ] }, { "cell_type": "code", "execution_count": 27, "metadata": { "collapsed": false }, "outputs": [ { "data": { "text/html": [ "
\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
121 (Division)2.a (Division)2.b (PGCD)1 (Vrai Faux)2 (Proba)3 (Proba)1 (Modélisation)1 (Explication)2 (Vérification) – bonus !
countNaNNaNNaNNaNNaNNaN25NaNNaNNaNNaN
\n", "
" ], "text/plain": [ " 1 2 1 (Division) 2.a (Division) 2.b (PGCD) 1 (Vrai Faux) \\\n", "count NaN NaN NaN NaN NaN NaN \n", "\n", " 2 (Proba) 3 (Proba) 1 (Modélisation) 1 (Explication) \\\n", "count 25 NaN NaN NaN \n", "\n", " 2 (Vérification) – bonus ! \n", "count NaN " ] }, "execution_count": 27, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# J'aimerai récupérer le nom des questions qui ont été le moins répondus\n", "notes_analysis[:1][notes_analysis[:1] == 25]" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [] } ], "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.4.3" } }, "nbformat": 4, "nbformat_minor": 0 }