set_test | R Documentation |
Setup test units (also known as gold units). If the answer/annotation is
wrong, coders receive damage. Note that which units are test units needs to
be indicated with the 'type' argument in create_units
.
set_test(
variable,
value,
field = NULL,
damage = 0,
on_wrong = NULL,
operator = "=="
)
variable |
The name of the variable as used in the codebook. If not specified, the name of the column will be used. |
value |
The value to which the given answer will be compared. Either a single string or the name of a column (in create_units). |
field |
Optionally, the name of a field (in case of a field specific annotation). |
damage |
The amount of damage a coder should receive. Can be a number or an expression that returns a number. |
on_wrong |
A markdown string that will be displayed when a coder gives an incorrect answer. If not given, no message will be displayed. Can also be the name of a column (in create_units) for unit specific messages. |
operator |
How should the annotation value be compared to the column value? Default is "==" (equals). Alternatives are "!=" (not equals), "<=", "<", ">=" or ">". |
A list of test units
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.