'How to merge multiple dataframes with one specific data frame in R

I have hundreds of excelfiles, which I want to import in R. After succesfull import, i want them all to merge with one specific dataframe, which I imported before. Is there a way to manage this together with the import? I thought of do.call(rbind...) but couldnt complete it. All files have the same columns, the filenames are pretty different but all ending with .xlsx. Here is my code for the import

for(i in filenames){
  filepath <- file.path("MyPath", paste(i,sep=""))
  assign(i, read.xlsx(i, grep('States-Money', getSheetNames(i))))
  do.call(rbind....)
}

Would be happy for any kind of help.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source