scale: Scaling and Centering of an H2OFrame

Description Usage Arguments Examples

Description

Centers and/or scales the columns of an H2O dataset.

Usage

1
2
## S3 method for class 'H2OFrame'
scale(x, center = TRUE, scale = TRUE)

Arguments

x

An H2OFrame object.

center

either a logical value or numeric vector of length equal to the number of columns of x.

scale

either a logical value or numeric vector of length equal to the number of columns of x.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
library(h2o)
h2o.init()
iris_hf <- as.h2o(iris)
summary(iris_hf)

# Scale and center all the numeric columns in iris data set
iris_scaled <- scale(iris_hf[, 1:4])

## End(Not run)

h2o documentation built on Oct. 10, 2021, 1:08 a.m.