title: How do I merge rows based on column and modify layout code in R?
body: <p>I have a .csv file that contains this:</p>
  
  <pre><code>84,62,175,235,374,221,292,375,430,497,0,0,736,0,0,0
  85,62,298,337,149,181,247,424,228,383,0,0,1657,0,0,0
  87,62,198,181,347,355,423,479,403,494,0,0,261,0,0,0
  88,62,289,202,422,310,388,430,498,604,0,0,259,0,0,0
  122,41,276,231,247,294,402,463,383,461,0,0,87,0,0,0
  </code></pre>
  
  <p>I have another .csv file that contains this:</p>
  
  <pre><code>10848,0,0,0,272826,84
  10849,0,0,0,272806,85
  10850,0,1,0,272812,85
  10851,1,0,0,440831,85
  10870,0,0,0,271567,122
  10871,0,1,0,438415,122
  </code></pre>
  
  <p>Using R, how can I merge these together (by first column in first table and last column in second) and add quotes to make it look nicer.</p>
  
  <p>Many thanks.</p>