Lock in $30 Savings on PRO—Offer Ends Soon! ⏳

Visualization

Eitan Lees
November 15, 2019

 Visualization

A talk about the theory of visualization

Eitan Lees

November 15, 2019
Tweet

More Decks by Eitan Lees

Other Decks in Education

Transcript

  1. “The ubiquity of visual metaphors in describing cognitive processes hints

    at a nexus of relationships between what we see and what we think” - Mackinlay & Card (1999)
  2. Part 1: Data Wrangling Part 2: Visual Encodings Part 3:

    Graphical Critique Part 4: Practical Advice
  3. Things to Consider: - Make Numbers ⇒ Numbers - Make

    Dates ⇒ Dates - Make Nans ⇒ Nans - Make sure strings aren’t corrupted
  4. country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000

    2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583
  5. country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000

    2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000 2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 Variables
  6. country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000

    2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000 2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 Variables country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000 2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 Observations
  7. country year key value Afghanistan 1999 cases 745 Afghanistan 1999

    population 19987071 Afghanistan 2000 cases 2666 Afghanistan 2000 population 20595360 Brazil 1999 cases 37737 Brazil 1999 population 172006362 Brazil 2000 cases 80488 Brazil 2000 population 174504898 China 1999 cases 212258 China 1999 population 1272915272 China 2000 cases 213766 China 2000 population 1280428583
  8. country year key value Afghanistan 1999 cases 745 Afghanistan 1999

    population 19987071 Afghanistan 2000 cases 2666 Afghanistan 2000 population 20595360 Brazil 1999 cases 37737 Brazil 1999 population 172006362 Brazil 2000 cases 80488 Brazil 2000 population 174504898 China 1999 cases 212258 China 1999 population 1272915272 China 2000 cases 213766 China 2000 population 1280428583 Variables country year key value Afghanistan 1999 cases 745 Afghanistan 1999 population 19987071 Afghanistan 2000 cases 2666 Afghanistan 2000 population 20595360 Brazil 1999 cases 37737 Brazil 1999 population 172006362 Brazil 2000 cases 80488 Brazil 2000 population 174504898 China 1999 cases 212258 China 1999 population 1272915272 China 2000 cases 213766 China 2000 population 1280428583
  9. country year key value Afghanistan 1999 cases 745 Afghanistan 1999

    population 19987071 Afghanistan 2000 cases 2666 Afghanistan 2000 population 20595360 Brazil 1999 cases 37737 Brazil 1999 population 172006362 Brazil 2000 cases 80488 Brazil 2000 population 174504898 China 1999 cases 212258 China 1999 population 1272915272 China 2000 cases 213766 China 2000 population 1280428583 Variables country year key value Afghanistan 1999 cases 745 Afghanistan 1999 population 19987071 Afghanistan 2000 cases 2666 Afghanistan 2000 population 20595360 Brazil 1999 cases 37737 Brazil 1999 population 172006362 Brazil 2000 cases 80488 Brazil 2000 population 174504898 China 1999 cases 212258 China 1999 population 1272915272 China 2000 cases 213766 China 2000 population 1280428583 country year key value Afghanistan 1999 cases 745 Afghanistan 1999 population 19987071 Afghanistan 2000 cases 2666 Afghanistan 2000 population 20595360 Brazil 1999 cases 37737 Brazil 1999 population 172006362 Brazil 2000 cases 80488 Brazil 2000 population 174504898 China 1999 cases 212258 China 1999 population 1272915272 China 2000 cases 213766 China 2000 population 1280428583 Observations
  10. country year key value Afghanistan 1999 cases 745 Afghanistan 1999

    population 19987071 Afghanistan 2000 cases 2666 Afghanistan 2000 population 20595360 Brazil 1999 cases 37737 Brazil 1999 population 172006362 Brazil 2000 cases 80488 Brazil 2000 population 174504898 China 1999 cases 212258 China 1999 population 1272915272 China 2000 cases 213766 China 2000 population 1280428583
  11. country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000

    2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 country year key value Afghanistan 1999 cases 745 Afghanistan 1999 population 19987071 Afghanistan 2000 cases 2666 Afghanistan 2000 population 20595360 Brazil 1999 cases 37737 Brazil 1999 population 172006362 Brazil 2000 cases 80488 Brazil 2000 population 174504898 China 1999 cases 212258 China 1999 population 1272915272 China 2000 cases 213766 China 2000 population 1280428583 We want to gather the values corresponding to each key.
  12. country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000

    2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 country year key value Afghanistan 1999 cases 745 Afghanistan 1999 population 19987071 Afghanistan 2000 cases 2666 Afghanistan 2000 population 20595360 Brazil 1999 cases 37737 Brazil 1999 population 172006362 Brazil 2000 cases 80488 Brazil 2000 population 174504898 China 1999 cases 212258 China 1999 population 1272915272 China 2000 cases 213766 China 2000 population 1280428583 Tidy We want to gather the values corresponding to each key.
  13. country 1999 2000 Afghanistan 745 2666 Brazil 37737 80488 China

    212258 213766 We want to spread the values to the corresponding keys.
  14. country year cases Afghanistan 1999 745 Afghanistan 2000 2666 Brazil

    1999 37737 Brazil 2000 80488 China 1999 212258 China 2000 213766 country 1999 2000 Afghanistan 745 2666 Brazil 37737 80488 China 212258 213766 We want to spread the values to the corresponding keys.
  15. country year cases Afghanistan 1999 745 Afghanistan 2000 2666 Brazil

    1999 37737 Brazil 2000 80488 China 1999 212258 China 2000 213766 country 1999 2000 Afghanistan 745 2666 Brazil 37737 80488 China 212258 213766 Tidy We want to spread the values to the corresponding keys.
  16. Tidy Data country year cases population Afghanistan 1999 745 19987071

    Afghanistan 2000 2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000 2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 Variables country year cases population Afghanistan 1999 745 19987071 Afghanistan 2000 2666 20595360 Brazil 1999 37737 172006362 Brazil 2000 80488 174504898 China 1999 212258 1272915272 China 2000 213766 1280428583 Observations Values
  17. Length Area Slope Position Angle Volume Color Value Color Hue

    Shape Visual Encoding Channels And many more ...
  18. Length Area Slope Position Angle Volume Color Value Color Hue

    Shape Accuracy ranking of quantitative perceptual tasks. Better Worse
  19. Nominal: - Labels and Categories - Example: Pill Shape -

    Operations: =, ≠ Ordinal: - Ordered Sets - Example: Drug Schedule - Operations: =, ≠, <, >
  20. Nominal: - Labels and Categories - Example: Pill Shape -

    Operations: =, ≠ Ordinal: - Ordered Sets - Example: Drug Schedule - Operations: =, ≠, <, > Quantitative: - Numerical Measurement - Example: Dosage - Operations: =, ≠, <, >, -, %
  21. 2D Plane Size Color Value Texture Color Hue Angle Shape

    Suitable for Ordered Data Suitable for Unordered Data
  22. 2D Plane Size Color Value Texture Color Hue Angle Shape

    Suitable for Ordered Data Position Area Color Value
  23. 2D Plane Size Color Value Texture Color Hue Angle Shape

    Suitable for Unordered Data Angle Color Hue Shape
  24. Position N O Q Size N O Q Color Value

    N O Q Texture N O Color Hue N Angle N Shape N Nominal Ordinal Quantitative Note: Q⊂O⊂N Bertin’s Levels of Organization
  25. Grammar of Graphics 1. Data 2. Transformations 3. Marks 4.

    Encoding - mapping from fields to mark properties 5. Scale - functions that map data to visual scales 6. Guides - visualizations of scales (axes, legends, etc.)
  26. Most of modern statistical graphics can be traced back to

    William Playfair a Scottish engineer and political economist. William Playfair
  27. Edward Tufte “Graphical excellence is that which gives to the

    viewer the greatest number of ideas in the shortest time with the least ink in the smallest space.” ― Edward R. Tufte, The Visual Display of Quantitative Information
  28. Edward Tufte “Graphical excellence is that which gives to the

    viewer the greatest number of ideas in the shortest time with the least ink in the smallest space.” ― Edward R. Tufte, The Visual Display of Quantitative Information
  29. Edward Tufte “Graphical excellence is that which gives to the

    viewer the greatest number of ideas in the shortest time with the least ink in the smallest space.” ― Edward R. Tufte, The Visual Display of Quantitative Information (within reason!)
  30. Sparklines “A sparkline is a small intense, simple, word-sized graphic

    with typographic resolution … ” - Edward Tufte, Beautiful Evidence, p. 46-63.
  31. Small Multiples “At the heart of quantitative reasoning is a

    single question: Compared to what? Small multiple designs answer directly by visually enforcing comparisons of changes, of the differences among objects, of the scope of alternatives.” - Edward Tufte, Envisioning Information, p. 67
  32. Ten Simple Rules for Better Figures By Nicolas P. Rougier

    1. Know your audience 2. Identify your message 3. Adapt the figure to the support medium 4. Captions are not optional 5. Do not trust the defaults 6. Use color effectively 7. Do not mislead the reader 8. Avoid “Chartjunk” 9. Message trumps beauty 10. Get the right tool
  33. 1. Know your audience 2. Identify your message 3. Adapt

    the figure to the support medium 4. Captions are not optional 5. Do not trust the defaults 6. Use color effectively 7. Do not mislead the reader 8. Avoid “Chartjunk” 9. Message trumps beauty 10. Get the right tool Ten Simple Rules for Better Figures By Nicolas P. Rougier
  34. 1. Know your audience 2. Identify your message 3. Adapt

    the figure to the support medium 4. Captions are not optional 5. Do not trust the defaults 6. Use color effectively 7. Do not mislead the reader 8. Avoid “Chartjunk” 9. Message trumps beauty 10. Get the right tool Ten Simple Rules for Better Figures By Nicolas P. Rougier
  35. 1. Know your audience 2. Identify your message 3. Adapt

    the figure to the support medium 4. Captions are not optional 5. Do not trust the defaults 6. Use color effectively 7. Do not mislead the reader 8. Avoid “Chartjunk” 9. Message trumps beauty 10. Get the right tool Ten Simple Rules for Better Figures By Nicolas P. Rougier
  36. 1. Know your audience 2. Identify your message 3. Adapt

    the figure to the support medium 4. Captions are not optional 5. Do not trust the defaults 6. Use color effectively 7. Do not mislead the reader 8. Avoid “Chartjunk” 9. Message trumps beauty 10. Get the right tool Ten Simple Rules for Better Figures By Nicolas P. Rougier