psychopy.org | Reference | Downloads | Github

Shape.stim and slider adjustment for non predefined stimulus attribute?

Hi,

I’m new to psychopy and python and I was just wondering whether or not it would be a relatively simple task to change some stimulus parameter with the visual.slider() that is not shape, or color or size or pos/ori which seem to have their own setOri() methods defined? In my experiment I’m using vertices as input for my shape.stim() which is a 2D array.

So if I made my own function which changes the Shape.Stim() output, is it possible for the visual.slider() to change my self created shape stimuli parameter?

Any advice/suggestions would be greatly appreciated.

Hi There,

Sounds doable! To clarify, are you trying to change the number of vertices using a slider? and are you wanting to run this only locally and not online?

Thanks,
Becca

Hi Becca,

yes I would like to update new vertices so eg. [32,2] 2d array update for every change in slider position. And running this only locally.

Hi there,

Ok so it’s the position of the vertices or the number of vertices that you are updating with the slider ? :slight_smile:

Becca

Hi Becca,

Sorry for not being more clear, I meant the position of vertices (xy coordinates) of my shape.stim updating with the slider. My input is always fixed size eg. [32,2] coordinates. So I was initially thinking of passing in new xy coordinates into my shape.stim for it to then draw on my window but wasn’t sure how that would integrate with the slider function.