> View(as.data.frame(c("xxxxxxxxxxxx","yyyyyyyyyyyyyyyyyyyyyyy",1,1)))
Error in dataviewer(x, title) : invalid argument

The problem is that View linearizes its argument to generate a title using
deparse(substitute(x)), which sometimes returns a vector of length > 1.

A simple fix is to change this to

      deparse(substitute(x),width.cutoff=500)[1]

There is apparently no way to specify no width cutoff in deparse, so the [1]
subscript restricts to the first element of the character array if there is
more than one.

In Windows, the title is apparently truncated at 256 characters anyway.  I
don't know about other OS's.

            -s

R version 2.9.1 (2009-06-26)
Windows XP

        [[alternative HTML version deleted]]

______________________________________________
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Reply via email to