randomization: no more than 3 trials of the same type in a row

Hi

I have an easy question.
I’m making a lexical decision experiment, in which the presentation of words and non-words is randomly alternated. However, I want Superlab to present no more than 3 words (or 3 non-words) sequentially. I suppose I should use macros but I’m unsure.
Thank for attention.

The experiment attached has four tracing events to test that the macros are working correctly. There are also macros that were created attached to the tracing events to tell SuperLab to present them within the experiment. Please feel free to delete them, or use them to test your own experiment.

  • Three code values were created
  • 1st code value "Ok to present words" with values "Yes" and "No"
  • 2nd code value "Ok to present Non-words" with values "Yes" and "No"
  • 3rd code value "Trial Type" with values "Words" and "Non-words"
  • For both trials the code values were tagged

  • Then, two macros were created. First macro is to look for 3 consecutive words

  • The Expression is "Number of Trials Presented in this Block is greater than or equal to 3 trials"
  • If True "Change value of code "Ok to present words" to "No" in all trials in this block"
  • If False "Change value of code "OK to present words" to "Yes" in all trials in this block
  • Second macro is to look for 3 words consecutive non-words
  • The Expression is "Number of Trials Presented in this Block is greater than or equal to 3 trials"
  • If True "Change value of code "Ok to present Non-words" to "No" in all trials in this block"
  • If False "Change value of code "OK to present Non-words" to "Yes" in all trials in this block

forums-psycho78.sl4 (8.49 KB)

This will be easier to do in the upcoming SuperLab 5 release by using counter type parameter.

Hi,

I am new and can not find how to post a new question on the forum.

I am more or less in the same position as “psycho 78”. I have followed your advice and the criteria of no more than three repitions is fulfilled. However the problem I am facing now is that superlab does not got through all my trials’ list.

Actually my experiment consists of two conditions (Go and No-Go), and I do not want any condition to be presented more than three times in a row. I have 80 Go and 40 No-Go. SO as mentiioned earlier, your macro prevents this but it stops before the supposed 120 trials. Most of the time it stops around 80 or 90 trials.

Btw the same problem occurs with the file you attached to your reply.

I also have another criteria but would first like this one to be taken care of.

Could you be able to help me out with this issue?

I would like to thank you in advance for your help.

You are right, I apologize about that. I have attached an updated experiment with the modifications below.

The problem with the earlier version was a macro was needed to repeat the block. The un-presented trials were not given a chance to be presented.

Also within the trials “Word Trials” and “Non-Word Trials” an expression was missing under the When to Present tab. It earlier stated "Current trial’s code “Ok to present words” is set to “Yes”. It also needed, and “Number of times this trial has been presented is equal to 0”.

forums-psycho78REVB.sl4 (8.74 KB)