minor changes related to github setup

Changed working directory in R code etc.
File cleanup

added separate script for variable construction