add .r file and update readme