Is this possible? I have found information on how to scale the experiment to the size of my monitor. But is there a way to detect the participant’s monitor dimensions, and scale the experiment to those?
If you use the “norm” unit for your visual objects, all the positions will be given relative to any particular display’s dimensions.
Hmm, as far as I can tell I am using norm units (i.e., I haven’t ever specified a unit for positions, but just put in numbers). I did set wrap width to 1.5. Could that be the issue?
I would use “height” units to scale stimuli to monitor height (whilst retaining aspect ratio and avoiding “squahing” of images for example).
To retrieve and store the window dimensions of the participants screen use:
note this retrieved window size, not monitor size - which is not possible from the browser without explicit input from your participant
Thanks! So I would add this at the beginning of the experiment? And then after that, would I have to do anything differently when defining the location of my objects?
Yes exactly, though remember your participant can change their window throughout your experiment (a limitation of online studies) - you might want to add this save call at a few points in your experiment to see if they do change the window.
But in terms of scaling I would recommend using height units.
If you want to scale the experiment to fixed sizes in cm, then you need something like my ScreenScale routine.
Gotcha! Looks like I’m already set to height units in the experiment settings.
The code you mentioned, will it affect presentation during the experiment? Or is that to add window size to the data?
Hi David, no won’t affect stim presentation - it’s only intended for saving info to your data file