r script and readme added