File: OptControl.R

package info (click to toggle)
r-cran-mlr 2.19.2%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 8,264 kB
  • sloc: ansic: 65; sh: 13; makefile: 5
file content (19 lines) | stat: -rw-r--r-- 769 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
makeOptControl = function(same.resampling.instance, impute.val = NULL, tune.threshold = FALSE,
  tune.threshold.args = list(), log.fun = "default", final.dw.perc = NULL, ...) {
  assertFlag(same.resampling.instance)
  if (!is.null(impute.val)) {
    assertNumeric(impute.val)
  }
  assertFunction(log.fun,
    args = c("learner", "task", "resampling", "measures", "par.set", "control", "opt.path", "dob", "x", "y", "remove.nas", "stage", "prev.stage"))
  assertFlag(tune.threshold)
  makeS3Obj("OptControl",
    same.resampling.instance = same.resampling.instance,
    impute.val = impute.val,
    tune.threshold = tune.threshold,
    tune.threshold.args = tune.threshold.args,
    log.fun = log.fun,
    final.dw.perc = final.dw.perc,
    extra.args = list(...)
  )
}