Outline for R package day 2. In separate file for now, while main file undergoes refactoring