Passer au contenu principal
SciNet
  • Accueil
  • Tous les cours
  • Calendrier
  • Certificats
  • SciNet
    Site principal Documentation my.SciNet
  • CCDB
  • Plus
Fermer
Activer/désactiver la saisie de recherche
Français
English Français
Vous êtes connecté anonymement
Connexion
SciNet
Accueil Tous les cours Calendrier Certificats SciNet Replier Déplier
Site principal Documentation my.SciNet
CCDB
Tout déplier Tout replier
  1. Tableau de bord
  2. BCH2203 - Winter 2022
  3. 2. Survey Analysis Improved

2. Survey Analysis Improved

Conditions d’achèvement
Ouvert le : mercredi 2 février 2022, 13:30
À rendre : mercredi 9 février 2022, 23:59

Start from the reference solution (below) for assignment 1.

Split this into three functions:

  1.  One function should read the data and store it in a 2-dimensional numpy array containing 0's and 1's (such that N becomes 0 and Y becomes 1).
  2. A second function should take such a numpy array as an argument and compute, for each of the questions, the percentage of 'N' and 'Y' answers.
  3. A third function should take such a numpy array and print the number of surveys with zero 'Y' answers, then the number of surveys with one 'Y' answer, with two 'Y' answers,  etc.

The new script should include these functions and then call these functions to achieve the same result as in assignment 1.

Use numpy functions where you can.  

Try this out on the data file from assignment 1. 

Use best practices.

The late policy is stated in the syllabus.

  • survey_analysis.py survey_analysis.py
    2 février 2022, 13:36
Contacter l’assistance du site
Vous êtes connecté anonymement (Connexion)
Résumé de conservation de données


All content on this website is made available under the Creative Commons Attribution 4.0 International licence, with the exception of all videos which are released under the Creative Commons Attribution-NoDerivatives 4.0 International licence.
Fourni par Moodle