Skip to content

Difference in Cat(...) function between S Plus and R ?

2 messages · Liu.Chunhua@epamail.epa.gov, Brian Ripley

#
Dear All,

THis is my "data.char$excluded" object and I want to show its content in
my output screen.
$names
[1] "Species" "Target"  "Sex"

[[2]]
[1] "DG"

[[3]]
[1] "R"

[[4]]
[1] "M"
When I run cat() in S Plus, I got:
c("Species", "Target", "Sex") "DG" "R" "M"

However, when I run the same commend in R, I got:
Error in cat(list(...), file, sep, fill, labels, append) :
        argument 1 not yet handled by cat

Anyone know what's wrong with it.

Thanks

Charlie Liu



-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help 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-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
#
Looks like it's a list, but you haven't told us (and the result of
typeof() would have helped).

If so, this is a known difference, and see ?unlist for how to help resolve
it.  I don't think though that what you show for `S Plus' is very useful,
and normally you want to loop over a list.
On Wed, 9 Jan 2002 Liu.Chunhua at epamail.epa.gov wrote: