transform_to_orig: Transform features to x.interest

Description Usage Value Arguments

View source: R/utils_counterfactuals.R

Description

Replace features of x by value of x.interest where use.orig is set to TRUE.

Usage

1
2
3
4
5
6
7
transform_to_orig(
  x,
  x.interest,
  delete.use.orig = FALSE,
  fixed.features = NULL,
  max.changed = NULL
)

Value

(list)

Arguments

x:

(list)
List of features, must have list element use.origin.

x.interest:

(data.frame)
Data frame with one row.

delete.use.orig:

(logical(1))
Whether to delete list element use.orig of x.

fixed.features:

(character)
Indicate fixed features by feature name.

max.changed:

numeric(1)
Number indicating how many feature are allowed to maximially differ from the original data point.


ArneRustad/prosjektoppgave documentation built on Dec. 17, 2021, 9:44 a.m.