Hello, I am currently learning both Python and this toolbox, so this might be an easy newbie question, regardless, thank you in advance for your time and help.
OS : Windows 10
PsychoPy version : 3.2.4
Standard Standalone? (y/n) : Yes
I am building an experiment in which I display a question and try to set the sliders response ‘ticks’ and ‘labels’ on every repeat. The loop received my conditions files and seems to recognize the individual parameters without a problem.
When applying the $Question to the text section it does display the question properly, but when I use the same approach for ticks: $AnswerTicks and labels: $AnswerLabels (both set to ‘Set every repeat’) I receive a ‘syntax error’.
To check the format for these two field I have copied the first row of parameters out of the excel file into the ticks/labels box under properties, this works fine. In case it matters, appearance has been set to ‘rating’. I have included screenshots below for reference.
I would love to know where I made a mistake and how to fix it. Thanks again for your support and knowledge!
My current set up, which produces the error:
Conditions file added to loop
with the two excel parameters shown:
Hi @Leonie_Forsman, this is not actually supported with the Slider by default, so you have to add some code where you recreate the slider on each routine, with the new ticks and labels. See the example attached. For this to work, you need to reformat your conditions file to match.
slid.psyexp (7.0 KB)
cond.xlsx (8.2 KB)
Hi @dvbridges, thank you so much! I managed to implement it, this works like a charm. Thanks again!
I tried to implement it in the way you suggested and in the experiment you provided it works perfectly, but as soon as I implement it in my existing experiment it does not work.
I have included 4 images (3 clickable stimuli), 1 mouse component, the code component and a loop around 3 routines: A (what I just described) → B → C -----> back to A and my slider in routine A never shows up on top of the image stimuli.
When I tried to do it in your provided experiment it worked to show the slider on top of the image, but in my experiment it doesn’t show up.
It should look somehow like this (of course the slider is not positioned correctly):
Do you have any idea what needs to be changed as soon as the loop runs over several components? Or do you think it interferes maybe with the mouse component, or what else could be the problem?
I am clueless…
Pyschopy 2020.1.3, windows10, firefox
So far I have tried many slight variations of this:
Conditions file looks like this:
Thanks in advance!
Hi there, this has now been solved in another thread Problems converting manually set sliders to psychoJS and this follow-up question can be disregarded. Thanks!