Conditional interval after a randomly timed stimulus

I would like to produce a within-trial delay period composed of interval A, distractor flash, and interval B. I need help to produce some conditional expression such that interval B can always be chosen based on a random interval A. Intervals A+B+distractor stimulus always sum to a fixed total delay period (for a total of either 1, 2 or 4 sec).

Here is a brief description of the trial protocol:
At the beginning of each trial participants will fixate (for 1 sec) at a central fixation mark on a black background. A visual cue is displayed for 200 ms. A delay period (1, 2 or 4 sec) follows the cue, and participants will continue to fixate. Within each delay period a distractor stimulus briefly appears once, and the time of appearance of the distractor within the delay period is random from trial to trial. A signal for response follows the delay, and a blank screen (for 1 sec) after the response until the end of the trial.

Is there a way to determine interval B depending on a random interval A within each trial?
Many thanks in advance.

I have attached a small sample experiment. The idea is to use two trials and pair them, it is important that they stay paired. This is done by using the Trial Variable for Screen Location feature. Within the trial variable Level Selection tab, be sure to choose “A New Group (between subjects)” under “Randomize levels”.

There is one disadvantage to this, participants in the same group will see the same exact sequence unless you create different groups for each participant.

centromears.sl4 (4.96 KB)

Same thing, more than 3 intervals

I have the same situation as centromears, but I have more than 3 intervals to sum up to a set time (15 or 20 sec time limit). The sequence of Stimulus A + distractor + Stimulus A most be repeated until the participant presses a key or the time limit has been reached. This means that the sequence could be repeated for up to 9 distractors. The duration of Stimulus A is randomly selected from a list of durations so that the distractor is unpredictable. The randomly selected durations of Stimulus A and the repeated distractor durations should add up to the total time limit if the participant makes no response.

I looked at the sample experiment provided by MonikaT but must admit I am not understanding how it achieves the goal. Could anyone offer guidance?

Thank you.

The workaround proposed earlier depends on a bug in SuperLab 4.5, it is being fixed as we speak in SuperLab 5. I have attached a demo of how to do this in SuperLab 5.

Some points to note:

  • Each trial must have 3 things in sequence
1. Interval A (this is required to be random) 2. Distractor Flash 3. Interval B (is based on whatever is chosen from A)
  • Both blocks do essentially the same thing. One block uses a Stimulus List, and the other block uses the same single distractor over and over
  • There are two Trial Variables, one for Interval A and the other for Interval B
  • There is an ISI event named "Interval A" that precedes the distractor. This event has a time limit based on Trial Variable A
  • There is a second ISI event named "Interval B" that follows the distractor. This event has a time limit based on Trial Variable B
  • Under the Trial Editor, under the Rules tab you will see the Rules that were created
  • The first Rule sets Interval A to some random level
  • The remaining rules adjust Interval B appropriately

t_1783.sl5 (7.33 KB)