2026-01-27
Good questions:
are easy for the person to answer
get you the information you’re asking for
Excerpted from So you want to be a wizard, (CC BY-NC-SA 4.0) by Julia Evans.
Adapted from So you want to be a wizard, (CC BY-NC-SA 4.0) by Julia Evans.
What is a reprex? It’s a reproducible example, as coined by Romain Francois in a tweet from 2014.
reprex()Adapted from reprex: Reproducible Examples with R by Jenny Bryan (CC-BY-SA 4.0).
Adapted from reprex: Reproducible Examples with R by Jenny Bryan (CC-BY-SA 4.0).
Conversations about code are more productive with:
This slide and the following slides on reproducible examples are adapted from reprex: Reproducible Examples with R by Jenny Bryan (CC-BY-SA 4.0).
Code is run in a new R session So, it must be self-contained.
Use the smallest, simplest, most built-in data possible.
Standard tricks for the inline creation of a small data frame.
data.frame()tribble()Many readers… can often get the point w/o running code, especially if they can see the output.
do not copy/paste from the R console (it takes fiddly edits to reproduce)
do not take a screenshot of your R session (it takes re-typing everything to reproduce)
How you ever helped a relative with a computer problem?
That is how it feels to answer a programming question based on a prose narrative.
“Making a good reprex is a lot of work!”
Yes! You are asking other people to experience your pain. Meet them halfway.
Making a good reprex often leads to solving your own problem. In private.
Adapted from So You Want to be a Wizard by Julia Evans.
“Love Your Bugs”
Adapted from So You Want to be a Wizard by Julia Evans building on Love your bugs by Allison Kaptur.
From So You Want to be a Wizard by Julia Evans building on Love your bugs by Allison Kaptur.
