search for: skogtemp_1

Displaying 1 result from an estimated 1 matches for "skogtemp_1".

2011 Jul 29
2
converting factor to numeric gives "NAs introduced by coercion"
...and the data are factors, how can avoid factors from the beginning? Although the file contains both characters and numbers. I tried to convert some of the columns from factor to numeric and as I understood it you can not use only as.numeric but as.character first. I got this warning message: > skogTemp_1 <- as.numeric(as.character(skogTemp_1[,2:4])) Warning message: NAs introduced by coercion I have lots of NAs in my data. Tries to check what class I had now but another warning is given me: > class(skogTemp_1[,2]) Error in skogTemp_1[, 2] : incorrect number of dimensions > class(skogTemp...