svm and naive bayes ensemble with h2o in r

#Train NB model in h2o and Cross-validate

nb.h2o <- h2o.naiveBayes(
x = x,
y = y,
training_frame = trainh2o,
nfolds = 10, # Number of CV folds (to generate level-one data for stacking)
laplace = 1
)

#SVM Model in h2o
#Train & Cross-validate SVM

svm.h2o <- h2o.psvm(x, y, training_frame = trainh2o, model_id = NULL,
validation_frame = testh2o, ignore_const_cols = TRUE, hyper_param = 1,
kernel_type = c("gaussian"), gamma = -1, rank_ratio = -1,
positive_weight = 1, negative_weight = 1,
disable_training_metrics = TRUE, sv_threshold = 1e-04,
fact_threshold = 1e-05, feasible_threshold = 0.001,
surrogate_gap_threshold = 0.001, mu_factor = 10,
max_iterations = 200, seed = -1)

Train a stacked ensemble using the NB and SVM above

ensemble <- h2o.stackedEnsemble(y = y, training_frame = trainh2o,
base_models = list(nb.h2o, svm.h2o))

Am getting this error...

Error: water.exceptions.H2OIllegalArgumentException: Base models are inconsistent: they use different values for nfolds.

Please help...

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.