null_model: General Interface for null models

Description Usage Arguments Details Engine Details See Also Examples

View source: R/nullmodel.R

Description

null_model() is a way to generate a specification of a model before fitting and allows the model to be created using R. It doesn't have any main arguments.

Usage

1
null_model(mode = "classification")

Arguments

mode

A single character string for the type of model. Possible values for this model are "unknown", "regression", or "classification".

Details

The model can be created using the fit() function using the following engines:

Engine Details

Engines may have pre-set default arguments when executing the model fit call. For this type of model, the template of the fit calls are below:

parsnip

null_model() %>% 
  set_engine("parsnip") %>% 
  set_mode("regression") %>% 
  translate()
1
2
3
4
5
6
## Model Specification (regression)
## 
## Computational engine: parsnip 
## 
## Model fit template:
## nullmodel(x = missing_arg(), y = missing_arg())
null_model() %>% 
  set_engine("parsnip") %>% 
  set_mode("classification") %>% 
  translate()
1
2
3
4
5
6
## Model Specification (classification)
## 
## Computational engine: parsnip 
## 
## Model fit template:
## nullmodel(x = missing_arg(), y = missing_arg())

See Also

fit()

Examples

1
null_model(mode = "regression")

parsnip documentation built on July 8, 2020, 7:22 p.m.