I am creating a color discrimination task for common crows where pecks to the correct colored circle result in a food reward. The basic structure of the experiment is as follows. A flashing stimulus appears, if it is clicked (pecked at) the experiment moves onto the color test, if it is not clicked they have a penalty phase with no stimuli before being presented with the flashing stimulus again. If they make it to the color test, there are two circles presented side by side. A correct click to the rewarded color leads to food and starts the trial over again and an incorrect click also starts the trial over again but with no food reward.
On each trial, I would like the color’s of the circle to be randomized with the rule that the same color can’t be on the same side more than twice. I currently have the color of the two circles set up with this excel format:
If I click random for the trial looptype, the first order presentation is random then the next is the opposite then random then opposite which gets us close to our goal but prevents an order like this BBAABB from ever occurring. If I click on full random, I get nicer randomization but can’t prevent cases like AAAAB which I would like to. Is there a way to constrain the fullrandom order such that the same row can’t be selected more than twice in a row?