add R codes to README