Structured files for future packaging.
Merge pull request #1 from emhart/master

Restructured code for packaging in R