R-alpha: cat

Robert Gentleman rgentlem@stat.auckland.ac.nz
Mon, 26 May 1997 08:55:10 +1200 (NZST)


Kurt,
  here's what S does (I recall going to some effort to duplicate the,
at times, seemingly unusual behaviour of cat)
S-PLUS : Copyright (c) 1988, 1996 MathSoft, Inc.
S : Copyright AT&T.
Version 3.4 Release 1 for Sun SPARC, SunOS 4.1.3_U1 : 1996 
Working data will be in /users/rdev/rgentlem/.Data 
>  x <- factor(c(1:3, NA), exclude=numeric(0))
> x
[1] 1  2  3  NA
> levels(x)
[1] "1"  "2"  "3"  "NA"
> cat(x, sep = "&")
1&2&3&4> cat(x, sep = "&\n")
1&
2&
3&
4
>

so, the behaviour of cat is the same (whether it's correct or not .....)

robert
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-