title: Using package "dplyr" to merge files creates multiple extra rows not in the original CSV files in R
body: <pre><code>library(&quot;dplyr&quot;)
  library(&quot;readr&quot;)
  library(&quot;tree&quot;)
  
  setwd(&quot;/Users/yingxiang/Documents/datamining/final proj&quot;)
  
  playerStats &lt;- list.files(path='/Users/yingxiang/Documents/datamining/final proj') %&gt;%
    lapply(read_csv) %&gt;%
    bind_rows
  </code></pre>
  <p>This is the code that I am using to combine 5 different csv files into one. When I run it, it adds many extra rows not in the original CSV files. In the first column, it is labeled as &quot;library(&quot;dplyr&quot;) #Load dplyr package&quot;. After that it looks like it is adding every other line of code that I have. What can I do to make it so that when I combine the CSV files that it will only use rows/columns from the CSV file.</p>
  <p><a href="https://i.stack.imgur.com/Cvj1t.png" rel="nofollow noreferrer">this is the csv output that i get</a></p>