| lvl_violation | R Documentation |
For each attribute level, count how often it occurs in the design candidate and find the distance to the nearest allowed number of occurrences. Levels that do not occur in the design candidate are counted as zero occurrences.
lvl_violation(
utility,
x,
rows,
ranges = occurrences(utility, rows),
lvls = expand_attribute_levels(utility)
)
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. |
x |
A design candidate with one column per attribute |
rows |
Number of rows in the design |
ranges |
Level occurrences as returned by |
lvls |
Attribute levels as returned by
|
The total distance summed over all attribute levels. A value of 0 means that the design candidate satisfies all level occurrence constraints.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.