Counterbalancing in OSweb
Dear all,
I've always counterbalanced my variables in inline scripts, but in OSweb this is not supported as far as I know. I have circumvened this issue with a dependency (i.e., "run if...") in a sequence item for one variable, but now I want to counterbalance more things and it becomes really messy. Any recommendations on how to do this?
Thanks a lot!

Comments
Hi @jsneuro,
You can use code to achieve complex counterbalancing, only you need to write it all in Javascript inside
inine_javascriptobjects. Could it be that you tried running Python code in OSWeb? That would not work (the compatibility check would stop it from even starting up, as OSWeb does not support coding in Python).Hope this helps!
Fabrice.
Okay, thanks. I didn't try the Python code, as I knew this was not supported, but right, I forgot about the Javascript inlines! I tried them 2 years ago, and got issues having them run. I am not really keen on sorting this out, so might move the experiment to the lab after all.
Hi @jsneuro,
Lab testing certainly makes things easier. Otherwise, OSWeb 1.4 has improved since the version you used two years ago. It's not more flexible. Alternatively, if you have complex sets of rules to generate pseudorandom lists of trials, another solution is to generate a stimuli lists in individual csv files (I typically do that in Visual Basic or Python), and then have the task to pick a stimulus file at random for each subject (OSWeb 1.4 supports populating loops from files).
Good luck with your experiment!
Fabrice.
Thanks Fabrice! Was hoping there was a solution, as in E-Prime (i.e., offset selection on basis of subject number), to counterbalance within the list object, but I will check out your suggestion.
@jsneuro
Maybe this can help: https://osdoc.cogsci.nl/3.3/manual/counterbalancing/#using-batch-session-data-jatos-and-osweb-only