title: read.table and files with excess commas
body: <p>I am trying to import a CSV file into R using the <code>read.table</code> command. I keep getting the error message "more columns than column names", even though I have set the strip.white to TRUE. The program that makes the csv files adds a large number of comma characters to the end of each line, which I think is the source of the extra columns. </p>
  
  <pre><code>read.table("filename.csv", sep=",", fill=T, header=TRUE, strip.white = T, 
             as.is=T,row.names = NULL, quote = "")
  </code></pre>
  
  <p>How can I get R to strip away the extraneous columns of commas from the header line and from the rest of the CSV file as it reads it into the R console?</p>
  
  <p>Also, numerous cells in the csv file do not contain any data. Is it possible to get R to fill in these empty cells with "NA"?</p>
  
  <p>The first two lines of the csv file:</p>
  
  <pre><code>Document_Name,Sequence_Name,Track_Name,Type,Name,Sequence,Minimum,Min_(with_gaps‌​),Maximum,Max_(with_gaps),Length,Length_(with_gaps),#_Intervals,Direction,Average‌​_Quality,Coverage,modified_by,Polymorphism_Type,Strand-Bias,Strand-Bias_&gt;50%_P-va‌​lue,Strand-Bias_&gt;65%_P-value,Variant_Frequency,Variant_Nucleotide(s),Variant_P-Va‌​lue_(approximate),,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
  Chr2_FT,Chr2,Chr2.bed,CDS,10000_ARHGAP15,GAAAGAATCATTAACAGTTAGAAGTTGATG-AAGTTTCA‌​ATAACAAGTGGGCACTGAGAGAAAG,55916421,56019336,55916483,56019399,63,64,1,forward,,,U‌​ser,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
  </code></pre>