Lab 10 guide

Lab 10 guide#

Goal: Get students to think ahead to the visualizations they want to produce, then work through the steps to get there.

First half#

Do the following as a group, with students directing.

  1. Pick a Dataset from the NYC Open Data Portal.

  2. Look at the columns/data through the Portal (don’t download).

  3. Decide how you want to visualize.

    • What columns should be used?

    • What chart type should be used?

    • Keep it simple.

      • Avoid anything that would require complex transformations.

      • For the purposes of this lab, it’s ok to cut corners.

    • Avoid using date/time columns - we’ll cover those in Week 11. Years are fine.

  4. Get the CSV URL.

  5. Create a new notebook.

  6. Read in the data.

  7. Do any necessary data cleaning.

  8. Create the visualization.

If you have time, repeat with a different visualization type, using a different dataset if you need. It’s ok if it’s a bit bumpy; use any dead ends as teachable moments.

Examples#

  • Using crash data, make a histogram of contributing factors.

  • Using city payroll data, make a scatterplot of base salary vs. total other pay.

    • You’ll need to deal with formatting / data types.

Second half#

Walk through Lab 10 Exercise.