Hi David, Thank you for your help. It worked!
Daniel Chan -----Original Message----- From: David Barron [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 27, 2006 9:29 PM To: Dan Chan; r-help Subject: Re: [R] Converting text to numbers > Then, I tried to convert them to numbers using the following. > > Sample1$FCT2 <- as.numeric(Sample1$FCT2) > > Sample1$OBS2 <- as.numeric(Sample1$OBS2) This is actually an FAQ. Do the following and it should be fine: > Sample1$FCT2 <- as.numeric(as.character(Sample1$FCT2)) > Sample1$OBS2 <- as.numeric(as.character(Sample1$OBS2)) -- ================================= David Barron Said Business School University of Oxford Park End Street Oxford OX1 1HP ______________________________________________ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.