View source: R/summary.fastml.R
summary.fastml | R Documentation |
Summarizes the results of machine learning models trained using the 'fastml' package. Depending on the task type (classification or regression), it provides customized output such as performance metrics, best hyperparameter settings, and confusion matrices. It is designed to be informative and readable, helping users quickly interpret model results.
## S3 method for class 'fastml'
summary(
object,
algorithm = "best",
type = c("all", "metrics", "params", "conf_mat"),
sort_metric = NULL,
...
)
object |
An object of class |
algorithm |
A vector of algorithm names to display summary. Default is |
type |
Character vector indicating which outputs to produce.
Options are |
sort_metric |
The metric to sort by. Default uses optimized metric. |
... |
Additional arguments. |
For classification tasks, the summary includes metrics such as Accuracy, F1 Score, Kappa, Precision, ROC AUC, Sensitivity, and Specificity. A confusion matrix is also provided for the best model(s). For regression tasks, the summary reports RMSE, R-squared, and MAE.
Users can control the type of output with the 'type' argument: 'metrics' displays model performance metrics. 'params' shows the best hyperparameter settings. 'conf_mat' prints confusion matrices (only for classification). 'all' includes all of the above.
If multiple algorithms are trained, the summary highlights the best model based on the optimized metric.
Prints summary of fastml models.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.