I am using read.table to import a text file within R. There are several "errors" in my text file. An "extra" quotation mark has inadvertently been included within a few text fields.
e.g. for a pipe (|) delimited text file, I have something similar to this: 1|7|30| "dog" 2|6|25| ""cat" 3|4|20|"" 4|5| 56| "mouse" 5|3|56| ""horse" 6|56| "" In the above example| there are extra quotation marks within the fields for cat and horse. (row 2 and row 5) e.g. "cat , "horse One solution is to simply edit the text file and remove the extra quotation mark. Is there a "good solution" I can implement form within R? I am OK with just importing the extra quotation marks and having nit show up as part of the text field within R. e.g, "cat "horse Thanks. [[alternative HTML version deleted]]
______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.