Re: [R] as.numeric in data.frame, but only where it is possible

2008-11-27 Thread hadley wickham
On Thu, Nov 27, 2008 at 12:53 AM, Kinoko <[EMAIL PROTECTED]> wrote: > Hi, > > I would like to convert my "character" sequences in my matrix/ > data.frame into "numeric" where it is possible. > I would also like to retain my alphabetic character strings in their > original forms. > "5.1" > 5.1

Re: [R] as.numeric in data.frame, but only where it is possible

2008-11-27 Thread Héctor Villalobos
Hello, On 26 Nov 2008 at 22:53, Kinoko wrote: > Hi, > > I would like to convert my "character" sequences in my matrix/ > data.frame into "numeric" where it is possible. > I would also like to retain my alphabetic character strings in their > original forms. "5.1" > 5.1 "hm" > "hm" >

[R] as.numeric in data.frame, but only where it is possible

2008-11-26 Thread Kinoko
Hi, I would like to convert my "character" sequences in my matrix/ data.frame into "numeric" where it is possible. I would also like to retain my alphabetic character strings in their original forms. "5.1" > 5.1 "hm" > "hm" k<-matrix(c("aa", "bb", 1,2, 4.3, 0), nrow=2) mode(k) <- "nume