This is what I packaged up as verification code for the Text mining in computational advertising labs page.
It is a primitive example of how to package up code for a paper. It is so
primitive that it is just a bash script, and manual steps are required for installing
dependencies. I manually installed lda, reshape, ggplot2 and their dependencies in to the site
library for all users at /usr/local/lib/R/site-library/
.