First, you need to add a file for Metadata Editor: drag & drop your R file or click inside the white area for choose a file. Then click the "View Metadata" button. It will now allow you to Download your R file.