Hi guys,
I am trying to merge a list of .xls files in google drive. I have now managed
to create a list of all the files I need, but for some reason I still can't
manage to merge them, this is the code I have so far:
library(googledrive) inputfiles <- drive_ls(path = "Email It In", pattern =
"*PDOL_dataexport", n_max = 50)
library(readxl) df.list<- lapply(inputfiles,function(x) read_xls(x))
library(dplyr) consolidated_data<-bind_rows(df.list)
The second part of the code throws up the following error:
Error: path must be a string
I must be entering the path (inputfiles) incorrectly for lapply, can someone
please help?
Thank in advance!
Ross
[[alternative HTML version deleted]]
______________________________________________
[email protected] mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.