search for: edadc

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

Did you mean: edac
2003 Aug 22
2
converting factor to numeric
...harder to remember, is as.numeric(levels(f))[as.integer(f)] In any case, do not call as.numeric() or their likes directly. But trying to follow the advice: (this is without package method attached, but the results are the same with): First doing as one shouldn't: > table( as.numeric(EdadC) ) 1 2 3 4 5 20 99 157 127 74 Doing as the FAQ says: > table( as.numeric(as.character(EdadC)) ) character(0) Warning message: NAs introduced by coercion or: > table( as.numeric(levels(EdadC))[as.integer(EdadC)] ) character(0) Warning message: NAs introduced by coercion...