Cubist models

knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)
library(tidypredict)
library(Cubist)
library(dplyr)

| Function |Works| |---------------------------------------------------------------|-----| |tidypredict_fit(), tidypredict_sql(), parse_model() | ✔ | |tidypredict_to_column() | ✔ | |tidypredict_test() | ✔ | |tidypredict_interval(), tidypredict_sql_interval() | ✗ | |parsnip | ✗ |

tidypredict_ functions

library(Cubist)
data("BostonHousing", package =  "mlbench")

model <- Cubist::cubist(x = BostonHousing[, -14], y = BostonHousing$medv, committees = 3)

Parse model spec

Here is an example of the model spec:

pm <- parse_model(model)
str(pm, 2)
str(pm$terms[1:2])


Try the tidypredict package in your browser

Any scripts or data that you put into this service are public.

tidypredict documentation built on Jan. 22, 2023, 1:41 a.m.