0

A similar question has been asked regarding read.csv, but I can't work this out myself.

I am trying to import about 28k lines of data from a CSV file using read.table. I get the error message:

In scan(file, what, nmax, sep, dec, quote, skip, nlines, na.strings,  :EOF within quoted string

And only a subset (about 7k lines) are imported. There doesn't seem to be anything wrong with the data where the import failed.

What does the error 'EOF within quoted string' mean exactly, and how can I find what is causing it?

Many thanks

Dan Lewer
  • 871
  • 5
  • 12
  • 2
    I had a dataset once where this happened, and the issue was that the strings weren't quoted, but did occasionally have quotes within them. If that's your situation, you can change what the quoting character is (including to nothing) with the `quote` option. – Aaron left Stack Overflow Nov 18 '13 at 21:07
  • I had the same question, which was answered here: http://stackoverflow.com/q/17414776/1036500 – Ben Nov 18 '13 at 21:24
  • Sometimes there are some “quote looking characters” in the string that aren't "really” quotes, just “look” like quotes, annoying stuck in there with Microsoft Word or some such autocorrecting nonsense. – Mike Christensen Nov 18 '13 at 21:27
  • Thank you very much - these answers solved my problem! – Dan Lewer Nov 20 '13 at 00:32

0 Answers0