| random | R Documentation |
Generates a random design by sampling from the candidate set each update of the algorithm.
random(
design_object,
model,
efficiency_criteria,
utility,
prior_values,
dudx,
candidate_set,
rows,
save_designs,
control
)
design_object |
A list of class 'spdesign' created within the
|
model |
A character string indicating the model to optimize the design for. Currently the only model programmed is the 'mnl' model and this is also set as the default. |
efficiency_criteria |
A character string giving the efficiency criteria to optimize for. One of 'a-error', 'c-error', 'd-error' or 's-error'. No default is set and argument must be specified. Optimizing for multiple criteria is not yet implemented and will result in an error. |
utility |
A named list of utility functions. See the examples and the vignette for examples of how to define these correctly for different types of experimental designs. |
prior_values |
A list of priors |
dudx |
A character string giving the name of the prior in the denominator. Must be specified when optimizing for 'c-error' |
candidate_set |
A matrix or data frame in the "wide" format containing
all permitted combinations of attributes. The default is NULL. If no
candidate set is provided, then it is built from the utility functions
subject to specified exclusions with |
rows |
An integer giving the number of rows in the final design |
save_designs |
A boolean indicating whether to save up to 10 intermediate designs. The default value is FALSE. |
control |
A list of control options. Set 'allow_reversed_pairs = TRUE'
to include the profiles of exchangeable alternatives in every order when the
candidate set is built. See |
With no restrictions placed, this type of design will only consider efficiency. There is no guarantee that you will achieve attribute level balance, nor that all attribute levels will be present. More efficient designs tend to have more extreme trade-offs.
A list of class 'spdesign'
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.