h2o.asnumeric | R Documentation |
If the column type is enum and you want to convert it to numeric, you should first convert it to character then convert it to numeric. Otherwise, the values may be converted to underlying factor values, not the expected mapped values.
h2o.asnumeric(x)
x |
An H2OFrame object. |
numeric
for the base R implementation, as.numeric()
.
## Not run:
library(h2o)
h2o.init()
f <- "https://s3.amazonaws.com/h2o-public-test-data/smalldata/junit/cars_20mpg.csv"
cars <- h2o.importFile(f)
h2o.ascharacter(cars)
h2o.asnumeric(cars)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.