Skip to main content
Version: v2.0.0-rc6

RepeatedComponentBlockCondition

Defined in: parser/types.ts:1060

The RepeatedComponentBlockCondition interface is used to define a SkipCondition based on the number of correct or incorrect repeated components. You might use this if you need to check if an attention check was failed multiple times. This is similar to the ComponentBlockCondition, but it only checks a specific repeated component.

Here's an example of how to use the RepeatedComponentBlockCondition:

{
...
"skip": [
{
"name": "attentionCheck",
"check": "repeatedComponent",
"condition": "numIncorrect",
"value": 2,
"to": "end"
}
]
...
}

In this example, when the number of incorrect responses to the repeated component with the name "attentionCheck" is two, the participant will be redirected to the end of the study. If the number of incorrect responses is less than two, the participant will continue to the next component in the sequence.

Properties

PropertyTypeDescriptionDefined in
check"repeatedComponent"The check we'll perform.parser/types.ts:1064
condition"numCorrect" | "numIncorrect"The condition to check.parser/types.ts:1066
namestringThe name of the repeated component to check (e.g. attentionCheck).parser/types.ts:1062
tostringThe id of the component or block to skip toparser/types.ts:1070
valuenumberThe number of correct or incorrect responses to check for.parser/types.ts:1068