conform.classification: Generate a conform.classification object

View source: R/conform.classification.R

conform.classificationR Documentation

Generate a conform.classification object

Description

Generate a conform.classification object

Usage

conform.classification(
  x,
  y,
  algorithm = c("standard", "mondrian", "knn", "weighted", "double"),
  type = c("ratio", "diff", "vovk"),
  train_method = "glm",
  train_p = 0.5,
  train_n = NULL,
  cal_n = NULL,
  cal_id = NULL,
  train_id = NULL,
  pretrained = NULL,
  ...
)

Arguments

x

data.frame or matrix of covariate data

y

vector of categorical responses

algorithm

method of conformal prediction

type

nonconformity score type

train_method

machine learning method from caret package for underlying model

train_p

size of proper training dataset by proportion of observations in x and y (default 0.5 split if train_n or train_id not specified)

train_n

size of proper training dataset by number n observations from x and y (both cal_n and train_n must be specified for this option)

cal_n

size of calibration dataset by number n observations from x and y (both cal_n and train_n must be specified for this option)

cal_id

list of indexes of selected calibration observations

train_id

list of indexes of selected proper training set observations (overides train_n and train_p)

pretrained

underlying caret model pretrained to pass into function

...

additional parameters for caret model training

Value

conform.classification object


labuzzetta/conformr documentation built on May 13, 2022, 12:50 a.m.