Moved R code to R-directory