added r script

r script