up Inquisit Language Reference

errorStreak property

The number of consecutive incorrect responses for the specified element within the current block.

Member of

<block> <expt> <likert> <openended> <sliderTrial> <survey> <surveyPage> <trial>

Syntax

event.name.errorStreak

Read Only

Type

integer

Remarks

This property can be used to define branches that apply when the participant makes a given number of consecutive incorrect responses.

Examples

The following displays the value of errorStreak in a text stimulus:

<text myText>
/ items= ("errorStreak = <% trial.myTrial.errorStreak %>")
</text>

The following displays the value of errorStreak in an instruction page:

<page myPage>
errorStreak = <% trial.myTrial.errorStreak %>
</page>

The following trial uses 'errorStreak' in its branching attribute: the trial runs for at least 5 times before the errorStreak is checked to see if the trial can be stopped. If the errorStreak is smaller than 3, the trial stops, otherwise it continues.

<trial choice>
/ inputDevice = mouse
/ stimulusFrames = [1 = choiceA, choiceB]
/ validResponse = (choiceA, choiceB)
/ branch = {
  if (trial.choice.trialCount < 5){//run the trial at least 5 times
    return this;
  } else if (this.errorStreak < 3){//stop if the current errorStreak is smaller than 3
    return null;
  } else {//otherwise continue with this trial
    return this;
  }
}
</trial>

Copyright Millisecond Software, LLC. All rights reserved.