I have been having trouble with a loop in my experiment. The first part of the loop is supposed to show the string in the experiment (coming from an excel file), followed by a screen for the participant to respond in. When I run the experiment, it goes through the first half ok, which has the a similar loop. When it gets to the second loop, it will run through the strings without showing the participant response on screen. When a key is pressed on the keyboard, it will move on to the next string without showing the key on the screen.
The difference between this loop and the first is that the text stimulus is in a different position, and the keyboard component limits the allowed keys to ‘g’, 'n, ‘backspace’, and ‘return’(the first loop allows all letters).
Any help with this would be appreciated, thank you!
From the looks of it, the Keyboard component is set the Force End Routine On Press (as it’s orange) - this should end the routine on a keypress. In your other Routine, is the Routine ended by the code component instead? If so then unticking Force End Routine is most likely the solution here.
@TParsons Hello, I tried this and it worked, thank you! If you don’t mind I have a second question. I would like to have the strings and the response on the same screen, so that participants can see the string and their response, and then proceed on their own time. Could I place a loop around one routine to do this?
If it’s already in a loop along with other routines then you should be able to access the contents of the corresponding conditions file, each iteration of the loop you can access the values within the current row by their column names.
So if I set it up like this it should be ok? Because I would like to arrange it so that the string would remain up on the screen while the participant responds, and they can move on on their own time. But when I run it now it cuts out right before the loop, and I’m not sure why.
Could you share the .psyexp file? It would help to see what that code component is doing and what conditions file that loop is connected to
Here it is:
CortexMini.psyexp (46.0 KB)
The loops don’t have the full set of strings, there are only two there right now to make it a bit easier to go through.
I’m not sure why this isn’t working, however it looks like what you’re trying to do is something which the new Textbox can do without any code, so it may be better to just replace the Text component with a Textbox set to be editable?
I replaced it with a Text component and it seems to be working, thank you!