ml_evaluate {sparklyr} | R Documentation |
Evaluate the Model on a Validation Set
Description
Compute performance metrics.
Usage
ml_evaluate(x, dataset)
## S3 method for class 'ml_model_logistic_regression'
ml_evaluate(x, dataset)
## S3 method for class 'ml_logistic_regression_model'
ml_evaluate(x, dataset)
## S3 method for class 'ml_model_linear_regression'
ml_evaluate(x, dataset)
## S3 method for class 'ml_linear_regression_model'
ml_evaluate(x, dataset)
## S3 method for class 'ml_model_generalized_linear_regression'
ml_evaluate(x, dataset)
## S3 method for class 'ml_generalized_linear_regression_model'
ml_evaluate(x, dataset)
## S3 method for class 'ml_model_clustering'
ml_evaluate(x, dataset)
## S3 method for class 'ml_model_classification'
ml_evaluate(x, dataset)
## S3 method for class 'ml_evaluator'
ml_evaluate(x, dataset)
Arguments
x |
An ML model object or an evaluator object. |
dataset |
The dataset to be validate the model on. |
Examples
## Not run:
sc <- spark_connect(master = "local")
iris_tbl <- sdf_copy_to(sc, iris, name = "iris_tbl", overwrite = TRUE)
ml_gaussian_mixture(iris_tbl, Species ~ .) %>%
ml_evaluate(iris_tbl)
ml_kmeans(iris_tbl, Species ~ .) %>%
ml_evaluate(iris_tbl)
ml_bisecting_kmeans(iris_tbl, Species ~ .) %>%
ml_evaluate(iris_tbl)
## End(Not run)
[Package sparklyr version 1.8.6 Index]