Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Teaching data science with puzzles

isteves
July 10, 2019

Teaching data science with puzzles

useR! 2019 Toulouse

isteves

July 10, 2019
Tweet

More Decks by isteves

Other Decks in Technology

Transcript

  1. Teaching data science
    with puzzles
    useR! 2019
    Irene Steves
    i_steves isteves bit.ly/ds-puzzles

    View full-size slide

  2. Unique puzzle input
    Answer submission
    Puzzle text

    View full-size slide

  3. I solved these
    with R, but boy
    was it clunky!

    View full-size slide

  4. Let’s make puzzles
    that highlight what
    R/the tidyverse are
    good at!

    View full-size slide

  5. Bite-sized puzzles that focus
    on core data science skills as
    championed by the tidyverse set
    of packages
    [still unreleased!]

    View full-size slide

  6. SOOTHSAYER. Beware the ides of March.
    CAESAR. What man is that?
    BRUTUS. A soothsayer bids you beware the ides of March.
    CAESAR. Set him before me; let me see his face.
    CASSIUS. Fellow, come from the throng; look upon Caesar.
    CAESAR. What say'st thou to me now? Speak once again.
    SOOTHSAYER. Beware the ides of March.
    CAESAR. He is a dreamer; let us leave him.
    The Death of Julius Caesar, Vincenzo Camuccini 1771-1844

    View full-size slide

  7. Photo: flickr clement127

    View full-size slide

  8. Wrangling Workflow

    View full-size slide

  9. Web-based experience
    Language & platform agnostic

    View full-size slide

  10. R-mediated
    experience
    Workflow

    View full-size slide

  11. New R Project

    View full-size slide

  12. Auto-generated
    table of contents

    View full-size slide

  13. Paths that work in the
    console & when rendered
    Knittable .R file
    Omit tidyverse
    messages from
    html output

    View full-size slide

  14. The neighborhood deli makes amazing
    sandwiches--from classics like BLTs to dessert
    sandwiches like Fluffernutters. Since many of
    their specialty ingredients keep going bad,
    they've decided to cut their selection and focus
    on their best-selling sandwich.
    Photo: flickr skywhisperer

    View full-size slide

  15. To help with the decision, the storeowners collected data on their customers’ favorites. Most
    people listed several varieties (in no particular order). Here’s a sample of the data:
    In this sample, the Dagwood sandwich is the most popular.
    In the full dataset, what is the most popular sandwich among the customers?

    View full-size slide

  16. test case
    In this sample, the Dagwood sandwich is the most popular.

    View full-size slide

  17. Photo: Wikipedia

    View full-size slide

  18. Beyond the
    Test cases
    Consistent and
    parseable names
    Projects
    & version
    control
    Self-contained
    code

    View full-size slide

  19. Thank you!
    bit.ly/ds-puzzles
    Irene Steves
    i_steves isteves

    View full-size slide