Singular value decomposition of an H2O data frame using the power method
h2o.svd(
training_frame,
x,
destination_key,
model_id = NULL,
validation_frame = NULL,
ignore_const_cols = TRUE,
score_each_iteration = FALSE,
transform = c("NONE", "STANDARDIZE", "NORMALIZE", "DEMEAN", "DESCALE"),
svd_method = c("GramSVD", "Power", "Randomized"),
nv = 1,
max_iterations = 1000,
seed = -1,
keep_u = TRUE,
u_name = NULL,
use_all_factor_levels = TRUE,
max_runtime_secs = 0,
export_checkpoints_dir = NULL
)
an object of class H2ODimReductionModel.
Id of the training data frame.
A vector containing the character
names of the predictors in the model.
(Optional) The unique key assigned to the resulting model. Automatically generated if none is provided.
Destination id for this model; auto-generated if not specified.
Id of the validation data frame.
Logical
. Ignore constant columns. Defaults to TRUE.
Logical
. Whether to score during each iteration of model training. Defaults to FALSE.
Transformation of training data Must be one of: "NONE", "STANDARDIZE", "NORMALIZE", "DEMEAN", "DESCALE". Defaults to NONE.
Method for computing SVD (Caution: Randomized is currently experimental and unstable) Must be one of: "GramSVD", "Power", "Randomized". Defaults to GramSVD.
Number of right singular vectors Defaults to 1.
Maximum iterations Defaults to 1000.
Seed for random numbers (affects certain parts of the algo that are stochastic and those might or might not be enabled by default). Defaults to -1 (time-based random number).
Logical
. Save left singular vectors? Defaults to TRUE.
Frame key to save left singular vectors
Logical
. Whether first factor level is included in each categorical expansion Defaults to TRUE.
Maximum allowed runtime in seconds for model training. Use 0 to disable. Defaults to 0.
Automatically export generated models to this directory.
N. Halko, P.G. Martinsson, J.A. Tropp. Finding structure with randomness: Probabilistic algorithms for constructing approximate matrix decompositions[https://arxiv.org/abs/0909.4061]. SIAM Rev., Survey and Review section, Vol. 53, num. 2, pp. 217-288, June 2011.
if (FALSE) {
library(h2o)
h2o.init()
australia_path <- system.file("extdata", "australia.csv", package = "h2o")
australia <- h2o.uploadFile(path = australia_path)
h2o.svd(training_frame = australia, nv = 8)
}
Run the code above in your browser using DataLab