R’ and RStudio are great but sometimes it’s better the just export your data to exploit them elsewhere or just show them to other people. Here is a review of possible techniques:

Export your data into a CSV

assuming your data is store inside df var, fairly simple:

Export your data into an excel file

A little bit more complex, we’ll use the ‘xlsx’ package

A few more tips for you:

I’ll like to use the sheetName option to explicitly name the tab. The default name is “Sheet1”. Quite useful to have a record of when the file has been generated for example. Replace last instruction what follows and you’ll be able to know.

Another good one that I like is to send the excel file to a Shared folder directly. Replace first instruction by

Of course, replace the file path by yours.

Send your data by email

If the data to send it not to big, another interesting idea is to send it by email using the ‘gmailr’ package.

* *