Fixed woops with R output, and style edits.