initRerandomizationExperimentalDesignObject: Begin a Rerandomization Search

Description Usage Arguments Value Author(s)

View source: R/rerandomization_search.R

Description

This method creates an object of type rerandomization_experimental_design and will immediately initiate a search through $1_T$ space for forced-balance designs.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
initRerandomizationExperimentalDesignObject(
  X = NULL,
  obj_val_cutoff_to_include,
  max_designs = 1000,
  objective = "mahal_dist",
  Kgram = NULL,
  wait = FALSE,
  start = TRUE,
  num_cores = 1
)

Arguments

X

The design matrix with $n$ rows (one for each subject) and $p$ columns (one for each measurement on the subject). This is the design matrix you wish to search for a more optimal design.

obj_val_cutoff_to_include

Only allocation vectors with objective values lower than this threshold will be returned. If the cutoff is infinity, you are doing BCRD and you should use the complete_randomization_with_forced_balanced function instead.

max_designs

The maximum number of designs to be returned. Default is 10,000. Make this large so you can search however long you wish as the search can be stopped at any time by using the stopSearch method

objective

The objective function to use when searching design space. This is a string with valid values "mahal_dist" (the default), "abs_sum_diff" or "kernel".

Kgram

If the objective = kernel, this argument is required to be an n x n matrix whose entries are the evaluation of the kernel function between subject i and subject j. Default is NULL.

wait

Should the R terminal hang until all max_designs vectors are found? The default is FALSE.

start

Should we start searching immediately (default is TRUE).

num_cores

The number of CPU cores you wish to use during the search. The default is 1.

Value

An object of type rerandomization_experimental_design_search which can be further operated upon.

Author(s)

Adam Kapelner


GreedyExperimentalDesign documentation built on Jan. 13, 2021, 5:57 a.m.