added R script and output