title: Reading multiple csv files faster into data.table R
body: <p>I have 900000 csv files which i want to combine into one big <code>data.table</code>. For this case I created a <code>for loop</code> which reads every file one by one and adds them to the <code>data.table</code>. The problem is that it is performing to slow and the amount of time used is expanding exponentially. It would be great if someone could help me make the code run faster. Each one of the csv files has 300 rows and 15 columns. 
  The code I am using so far:</p>
  
  <pre><code>library(data.table)
  setwd("~/My/Folder")
  
  WD="~/My/Folder"
  data&lt;-data.table(read.csv(text="X,Field1,PostId,ThreadId,UserId,Timestamp,Upvotes,Downvotes,Flagged,Approved,Deleted,Replies,ReplyTo,Content,Sentiment"))
  
  csv.list&lt;- list.files(WD)
  k=1
  
  for (i in csv.list){
    temp.data&lt;-read.csv(i)
    data&lt;-data.table(rbind(data,temp.data))
  
    if (k %% 100 == 0)
      print(k/length(csv.list))
  
    k&lt;-k+1
  }
  </code></pre>