Incrementing the range of a selection variable

Hi Chris,
I was wondering if there’s a smart way to increment the range of a selection variable. I’d like to have blocks of trials where a variable is selected randomly from 0:n for block n. I could do this with just normal variables and rand() but I figured there’s probably some advantage to using selection variables.

In particular, it’d be nice if the selection variable wasn’t reinitialized, so that the “next selection” is biased away from the previous block’s selections. For instance, in block 1, the variable is set to 0 or 1, and in block 2, it will get selected as 2 more often than 0/1 so that all 3 values get selected approximately equally times in total. Once again, I could hardcode this with normal variables and some distribution on rand(), but I’m wondering if there’s a clever way of doing it. Let me know!
Thanks,
Rishi

Hi Rishi,

It’s not immediately obvious to me if/how you could do this with selection variables. Let me think about it a bit and get back to you.

Chris

Hi Rishi,

I still don’t see any way to make this work with selection variables. It might be possible to get the behavior you want with normal variables and rand(), though I’m not fully convinced yet. Alternatively, it could be done with the aid of a Python bridge script or (as a last resort) a custom plugin. Should I explore those options further, or are you content with your current workaround(s)?

Thanks,
Chris

Hi Chris,
Thanks. No need to explore workarounds, I’m satisfied with the current
method.
Best
Rishi