I have a directory with three xlsx files:
my_path <- c('Path/To/My/Stuff')
And each of the files has a name like this: my-file_1.xlsx, my-file_2.xlsx, my-file_3.xlsx
I want to combine these three files into a new xlsx workbook where each sheet contains all the data for one of these standalone files, and is also named after the standalone file (but only the file_N ending piece.
For example, the master workbook would be called my-complete-workbook.xlsx and it would have three tabs: file_1, file_2, file_3.
What's the best way to achieve this in R, ideally using the openxlsx library?