tests/testthat/test-OptimCART.R

context("OptimCART")

test_that("Test CART with Australian Credit", {
  #Train a simply model
  modelFit <- Optim.CART(Y~., AustralianCredit, p = 0.7, seed=2018)
  expect_equal(class(modelFit), "Optim")
  #Print
  print(modelFit, plain=TRUE)
  print(modelFit, plain=FALSE)

  summary(modelFit)
  })

Try the OptimClassifier package in your browser

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

OptimClassifier documentation built on Jan. 14, 2020, 5:10 p.m.