This tutorial demonstrates how to use the Switch Node in an experiment, to allow participants to switch between two tasks. In this example, we want participants to be able to view the task instructions at any point during the main task. To achieve this, we have created a separate task for the instructions.
Within the main task, we have added a Button with a Click Response component. The Label on the button is 'View Instructions', to make it clear to participants. The Response recorded by the Click is 'switch'. Then, we add a Switch component to the screen. Here, we set the Criteria to be the Response 'switch', to match the Click Response from the Button. When we receive this response, the Switch will be activated. This setup is also implemented within the Instructions task, to allow participants to switch back to the main task.
To allow for the switching between tasks, we must add the Switch Node to the experiment tree. When using the Switch Node, there must be a Primary Task and a Secondary Task. In this example, the main task is the Primary Task, and the Instructions is the Secondary Task. We connect the tasks to the Switch Node to reflect this. Then, within the Switch Node, we leave the Max Switches field blank to allow for unlimited switches. The Completion Criteria for the switching task is to Complete Primary Task. For this reason, we leave the Total Time Limit field blank as well.
This set up allows for participants to switch back and forth between the tasks and the instructions as many times as they wish.