Press "Enter" to skip to content

Conditional Branching is coming to FindingFive!

Note that the code examples on this page are outdated. Please refer to the FindingFive study grammar for how to use conditional branching on FindingFive.

A common design in many behavioral studies is to show participants different sequences of trials that are conditional on participants’ previous responses. For example, in a typical learning study that features a training phase and a testing phase, researchers often wish to only allow participants who achieve reasonable learning during the training phase to continue into the testing phase. “Non-learners” are disqualified to keep the resulting data more interpretable.

There are many different names for this type of study design. In this blog, and throughout FindingFive’s system, we’ll call it Conditional Branching. That is, conditional on their responses, participants will branch into different paths within the same study.

Photo downloaded from (Photographer: Pixabay

A Projected Release Date in June

FindingFive doesn’t support conditional branching yet, and that is about to change very soon! We have been working very hard for the past 6 months to design and implement an intuitive solution to conditional branching. We estimate that we shall be ready to release this feature by the end of June.

Sneak Peek: Branching Blocks and Branches

Conditional Branching is achieved by two parts working together: a new branching block and the definition of branches in the property “block_sequence” of the procedure.

A branching block has all the features of a regular block, such as defining what trial templates to use and how they are arranged in order. Additionally, a branching block also contains branching instructions. Here’s an example:

<pre class="CodeMirror cm-s-default" data-setting="%1$s">"branching_block1": {
  // a branching block has all features of a regular block
  "cover_trials": ["instruction_template"],
  "trial_templates": ["spr_sentences", "spr_questions"],
  "pattern": {"order": "alternate"},
  // additionally, it supports branching instructions
  "branching": {
    // specify the branching evaluation method, which could be either "accuracy" or "match"
    "method": "accuracy", 
    // select the participant responses that should be evaluated
    "triggers": {"spr_questions": "choice_response1"}, 
    // for accuracy, this defines the threshold
    "min_score": 0.8, 
    // if a participant meets the accuracy threshold, they go to "branch1", otherwise, "branch2"
    "branches": {"branch1": true, "branch2": false}

That is, branching instructions identify a subset of participant responses that are relevant to the branching actions (i.e., “triggers”), and define an evaluation method on those triggers. When the branching block reaches its end, this evaluation will occur. The instructions also contain information on how to branch given the results of the evaluation. In the above example, if the participant achieved an accuracy of 80% in responses “choice_response1” from the template “spr_questions”, then they should proceed to “branch1”; otherwise, they should be shown the trials in “branch2”.

What are those branches, “branch1” and “branch2”? Well, we define them in the “block_sequence” of the procedure, using a syntax that is identical to the definition of participant groups:

<pre class="CodeMirror cm-s-default" data-setting="%1$s">"block_sequence": [
  // here come the branches
  {"branch1": ["continue_block"], "branch2": ["goodbye"]}

That’s very straightforward, isn’t it? 😀

Differences from Participant Grouping

As we have already alluded to, FindingFive has introduced a feature called Participant Grouping for some time. Participant grouping is used to assign N participants into K equally-sized groups so that each group experiences a unique sequence of trials (i.e., what psychologists typically refer to as “conditions”).

The key difference between participant grouping and conditional branching is that the assignment of groups happens at random, independently of what the participant does in the study. The assignment of branches, on the other hand, depends on participant responses.

So, you can think of conditional branching as “Conditional Participant Grouping”. Or, if you prefer, you can think of participant grouping as “Unconditional branching”.

Interactions with Participant Grouping

In general, participant grouping takes the priority over conditional branching. That is, we will support both:

  • Group-specific branches: All groups experience the same branching block test, and then the branches differ by groups. In other words, “Branch1” for “Group1” can be defined differently from “Branch1” for “Group2”.
  • Group-specific branching: Different groups experience different branching blocks, or some groups may even not branch at all.

In a later post after the release of conditional branching, we will describe how to mix up participant groups and conditional branching to create powerful and flexible experimental designs. I’m very excited about that!

What we don’t support is nested definitions of groups within branches. We believe that is an extremely uncommon case, and will likely be very confusing.

Temporary and Semi-Permanent Limitations

In developing this feature, we have learned that conditional branching can get very complex, and therefore made some arbitrary decisions. Some of those decisions are:

  • At this moment, conditions must be evaluated at the end of a branching block. In some cases, researchers may want to abort training immediately, using the above example, once a participant achieves the desired accuracy threshold. Such a design is currently not possible with our implementation, but we are considering supporting it in the future.
  • At this moment, we will support two branching evaluation methods: accuracy, which evaluates whether a participant achieves a certain accuracy threshold, and match, which evaluates whether a participant’s response matches a preset answer (we do support multi-way match). We are considering supporting more methods in the future.
  • We are unlikely to ever support nested branching. That is, participants in different branches further branch differently. If you have a study requiring such a design, please get in touch with us.

Impact on Your Studies

The inclusion of Conditional Branching should not have any effect on your existing studies that do not make use of the feature.

Feedback Welcome

If you have any thoughts on this upcoming feature, please get in touch with us! We’re always available at!

Comments are closed.