#' @include mlr.measures.R
#' @include Measure.R
mlr.measures$add(Measure$new(
id = "mse",
description = "Mean squared error",
task.types = c("regr"),
fun = function(pred) {
mean((pred$truth[[1L]] - pred$predicted)^2)
}
))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.