Skip to content

A8 - Working with Excel and Plotting Graphcs

Befort you start

Open a command prompt window (search for cmd in the Windows search bar), and type in the following commands:

  • pip install matplotlib
  • pip install openpyxl

Also run the update to get the sample files. They will go into a subfolder within your Python folder called survey.

Run the sample-survey.py file to take a survey, then run the sample-results.py file to see the results. Also open the excel file to see how the survey data is stored.

Your Main Task

Create your own survey in the same way. I would start by making copies of each of the files, then rename each of them appropriately, then modify them as necessary.

Extensions

Here are some links that provide more information on Python's matplotlib module:

Go through some of this, and try to create some different types of plots using data of your choice. You can either pull the data from Excel like we did for the survey, or hard code the data into your code (a little easier).