
Begin a Binary Match Search
Source:R/binary_match_search.R
initBinaryMatchExperimentalDesignSearchObject.RdThis method creates an object of type pairwise_matching_experimental_design_search and will immediately initiate
a search through allocation space for pairwise match designs based on the structure computed in the function computeBinaryMatchStructure.
For debugging, you can use set the seed parameter and num_cores = 1 to be assured of deterministic output.
Usage
initBinaryMatchExperimentalDesignSearchObject(
binary_match_structure,
max_designs = 1000,
wait = FALSE,
start = TRUE,
num_cores = 1,
seed = NULL,
prop_flips = 1,
verbose = TRUE
)Arguments
- binary_match_structure
The
binary_experimental_designobject where the pairs are computed.- max_designs
How many random allocation vectors you wish to return. The default is 1000.
- wait
Should the
Rterminal hang until allmax_designsvectors are found? The default isFALSE.- 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.- seed
The set to set for deterministic output. This should only be set if
num_cores = 1otherwise the output will not be deterministic. Default isNULLfor no seed set.- prop_flips
Proportion of flips. Default is all. Lower for more correlated assignments (useful for research only).
- verbose
Should the algorithm emit progress output? Default is
TRUE.
Examples
if (FALSE) { # \dontrun{
set.seed(1)
X = matrix(rnorm(16), nrow = 8)
bms = computeBinaryMatchStructure(X)
bm = initBinaryMatchExperimentalDesignSearchObject(
bms,
max_designs = 4,
num_cores = 1,
start = TRUE,
wait = TRUE,
seed = 1,
verbose = FALSE
)
bm
} # }