Creating Good Graphics

Course Evaluations

  • Please complete your course evaluation

  • Constructive suggestions for how to change things are welcome

  • This class is NOT supposed to be easy - that it is hard is OK, but it should feel do-able

  • The main goal of Stat 151 is to convince you that you can use R/python to do things with data

Reading and Resources

Screenshot of the first section of the [textbook chapter on good graphics](https://srvanderplas.github.io/stat-computing-r-python/part-wrangling/02c-good-graphics.html).

Other useful things:

Motivation and Inspiration

  • fonts are unreadable (and don’t match!)
  • why use an orange background?? sub-optimal color contrast
  • dual y-axis
  • log scales on both y axes
  • plotting the standard deviation (not ideal)
  • x-axis labels aren’t legible
  • x-axis gridlines dominate the whole plot
  • x-axis appears to be categorical?
    • Line chart (bottom set of data) isn’t appropriate
    • scatterplot with categorical x-axis not optimal (sometimes ok)
  • Bottom set of data: points make the lines hard to see
  • Top set of data (points) have different colors but no legend
  • Poor color contrast between some of the point colors
  • Can’t tell which set of data goes with which axis

I’m sure there are more…

Homework 12

  • Use github classroom to accept the assignment
  • Don’t forget to commit and push your changes!
    • You don’t have to wait until the assignment is complete to push!
    • Push early and often!

Hints and Clarifications

  • The goal is to customize a ggplot or seaborn plot as much as possible

  • Have fun with it!

  • The most important part of this is your explanation of why your choices make the chart bad

    • Back up the explanation with things discussed in the textbook

Coming Up

  • Next week: In-class practice exam live coding demonstration

    • Complete the practice exam as Homework 13
    • Points on the assignment would be how I would grade it if it were an exam
    • The homework assignment is still only 10 points
    • No resubmission option for HW 13

Coming Up

  • Finishing Up:
    • Homework resubmission deadline is May 5th (Monday)

    • Final Exam - May 15th, 1-3 pm, Hardin 163

    • Oral Final Exams

      • I will message you via Canvas by 8pm on May 15
      • You must schedule your appointment by 8am on May 16
      • Appointment must be before 2pm on May 16
      • Make sure you have at least 2 30-minute slots available between 8am and 2pm on May 16