target_encode_apply: Applies a preparation map

Description Usage Arguments

View source: R/fte.R

Description

Applies a preparation map

Usage

1
2
3
target_encode_apply(data, group_variables, outcome_variable,
  preparation_map, holdout_type = "none", prior_sample_size = 30L,
  noise_level = 0, seed = 1793)

Arguments

data

data.frame()
Data to apply the target encode preparation map to.

group_variables

character()
On which categorical variables to apply the target encoding?

outcome_variable

character()
Name of the column representing the boolean outcome.

preparation_map

data.frame()
Preparation map formatted as the expected output from target_encode_create.

holdout_type

character(1)
The holdout type used. Must be one of: "LeaveOneOut", "None".

prior_sample_size

integer(1)
If non-zero, then a bayesian blended average is computed. The prior_sample_size defines the weight of the population mean compared to the sample mean.

noise_level

float(1)
The amount of random noise added to the target encoding. This helps prevent overfitting. Defaults to 0.01.

seed

integer(1)
Seed for reproductible random values.


signaux-faibles/fte documentation built on Jan. 29, 2020, 8:07 p.m.