[R] typo in read.table and count.fields?

Peter Dalgaard BSA p.dalgaard at biostat.ku.dk
Fri Jan 31 13:51:02 CET 2003


Claudio Agostinelli <mail-list at linaria.dst.unive.it> writes:

> It seems that in read.table and count.fields there is a typo in the quote
> parameter.
> 
> read.table(file, header = FALSE, sep = "", quote = "\"'", dec = ".",
>            row.names, col.names, as.is = FALSE, na.strings = "NA",
>            colClasses = NA, nrows = -1,
>            skip = 0, check.names = TRUE, fill = !blank.lines.skip,
>            strip.white = FALSE, blank.lines.skip = TRUE,
>            comment.char = "#")
> 
> presents in R-devel   .tar.gz file of today and in R-1.6-2
> 
> > args(read.table)
> function (file, header = FALSE, sep = "", quote = "\"'", dec = ".",
>     row.names, col.names, as.is = FALSE, na.strings = "NA", colClasses =
> NA,
>     nrows = -1, skip = 0, check.names = TRUE, fill = !blank.lines.skip,
>     strip.white = FALSE, blank.lines.skip = TRUE, comment.char = "#")
> NULL

Ehh.... what typo? quote is a string consisting of the two possible
quoting characters, " and ', and to display such a string, the " needs
to be escaped within "...".

-- 
   O__  ---- Peter Dalgaard             Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics     2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark      Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk)             FAX: (+45) 35327907




More information about the R-help mailing list