added R script