Nothing
test_that("datadictionary error when features with unsupported class are used in tree model", {
skip_if_not_installed("rpart")
library(rpart)
data(kyphosis)
kyphosis[1, 2] <- ""
kyphosis[2, 2] <- NA
expect_error(pmml(rpart(formula = Kyphosis ~ Age + Number + Start, data = kyphosis)), "character class is not supported for features. Supported classes: numeric, logical, factor.")
})
test_that("datadictionary error when features with unsupported class are used in linear model (lm)", {
test <- data.frame(x1 = rnorm(100), x2 = sample(c("a", "b"), 100, TRUE), y = rnorm(100), stringsAsFactors = FALSE)
expect_error(pmml(lm(y ~ x1 + x2, data = test)), "character class is not supported for features. Supported classes: numeric, logical, factor.")
})
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.