Re: [Rd] format() applied to an NA character string (PR#9616)

2007-04-18 Thread ripley
On Wed, 18 Apr 2007, Peter Dalgaard wrote: > [EMAIL PROTECTED] wrote: >> I get strange results when I try to format() an NA character string. >> >> >>> x <- 'sometext' >>> x[1] <- NA >>> format(NA, width=32) # displays sensibly, right-justified >>> format(x,width=32) # displays sensibly, left-ju

Re: [Rd] format() applied to an NA character string (PR#9616)

2007-04-18 Thread Gregor Gorjanc
Peter Dalgaard biostat.ku.dk> writes: > This happens on Linux too, given slightly larger widths: > > R version 2.5.0 RC (2007-04-17 r41210) > > > x <- as.character(NA) > > format(x,width=64) I can confirm this on Linux also. > format(x,width=36) [1] "NA "

Re: [Rd] format() applied to an NA character string (PR#9616)

2007-04-18 Thread Peter Dalgaard
[EMAIL PROTECTED] wrote: > I get strange results when I try to format() an NA character string. > > >> x <- 'sometext' >> x[1] <- NA >> format(NA, width=32) # displays sensibly, right-justified >> format(x,width=32) # displays sensibly, left-justified >> format(x,width=33) # displays "" >> f

[Rd] format() applied to an NA character string (PR#9616)

2007-04-18 Thread D . Wischik
I get strange results when I try to format() an NA character string. > x <- 'sometext' > x[1] <- NA > format(NA, width=32) # displays sensibly, right-justified > format(x,width=32) # displays sensibly, left-justified > format(x,width=33) # displays "" > format(x,width=36) # R exits abnormal