title: Append multiple csv files into one file using R
body: <p>I Have multiple csv files that i have already read into R. Now I want to append all these into one file. I tried few things but getting different errors. Can anyone please help me with this?</p>
  
  <p>TRY 1:</p>
  
  <pre><code>mydata &lt;- rbind(x1,x2,x3,x4,x5,x6,x7,x8)
  </code></pre>
  
  <p>WHERE XI,X2....X8 Are the  CSV files I read into R, error I am getting is </p>
  
  <p>ERROR 1 :In <code>[&lt;-.factor</code>(<code>*tmp*</code>, ri, value = c(NA, NA, NA, NA, NA, NA, NA,  :
    invalid factor level, NA generated</p>
  
  <p>TRY 2: Then I try this in another way :</p>
  
  <pre><code>mydata1&lt;- c(x1,x2,x3,x4,x5,x6,x7,x8)
  &gt; mydata2 &lt;- do.call('rbind',lapply(mydata1,read.table,header=T))
  </code></pre>
  
  <p>Error 2: in FUN(X[[i]], ...) : 
    'file' must be a character string or connection</p>
  
  <p>can anyone please help me know what is the right way to do this?</p>