Yeah, I see this too. But in my course, submitting the work = pushing the
.Rmd and the rendered
.md to GitHub. It only takes one (temporary) mark of 0 to really make the point that the
.Rmd must actually load any packages that it uses.
I freely acknowledge that every teaching environment is different. I'm dealing with graduate students, over the course of 13 weeks. This means I am able to take a hard line that they must write code that is self-contained, because it's how they need to work long-term.
I know that @mine and Colin Rundel use wercker with their undergrads, so the students can catch these obvious problems, such as not including
library() calls, prior to HW submission. But that's feasible because they (the instructors) control the students' computing environment.