Added some code to the R file. Need to find my notes from Ben meeting. Added some front end to the tex file.