Hi
> Hello-
>
> I have rather a messy SPSS file which I have imported to R, I've dput'd
> some of the columns at the end of this message. I wish to get rid of all
> the labels and have numeric values using as.numeric. The funny thing is
> it works like this:
>
> as.numeric(mydata[,2]) # gene
Perfect, many thanks for explanation and correct line of code.
On 09/01/2012 14:29, peter dalgaard wrote:
as.data.frame(lapply(mydata, as.numeric))
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the p
On Jan 9, 2012, at 15:11 , Chris Beeley wrote:
> Hello-
>
> I have rather a messy SPSS file which I have imported to R, I've dput'd some
> of the columns at the end of this message. I wish to get rid of all the
> labels and have numeric values using as.numeric. The funny thing is it works
> l
Hello-
I have rather a messy SPSS file which I have imported to R, I've dput'd
some of the columns at the end of this message. I wish to get rid of all
the labels and have numeric values using as.numeric. The funny thing is
it works like this:
as.numeric(mydata[,2]) # generates correct numbe
4 matches
Mail list logo