Unable to convert object to a number

If this template helps then use it. If not then just delete and start from scratch.

OS : Win10
PsychoPy version : 2024.2.4
Standard Standalone Installation? (y/n) If not then what?:
**URL of experiment: ** Sign in · GitLab stim_presentation [PsychoPy]

Hello, I built an experiment in Builder where images are shown iteratively inside a circle. Positions (in cm) are updated at each repeat using the coordinates saved in a condition.xlsx file.

This is the error I get, which is linked to the conversion of coordinates from the excel file:

I don’t know how to solve this because the previous threads deal with problems linked to code components, while in my script I have no code components at all.

Thank you a lot for the help,
Best wishes,
Isotta

The easiest solution is to have two columns in your spreadsheet (fig_posx and fig_posy) and then set the position as (fig_posx, fig_posy). No dollar sign is needed.

If I do this, I don’t have this problem anymore indeed. However, I get another error, linked to the unit of measurements:

Error

Unfortunately we encountered the following error:

  • when converting a position to pixel units
  • unknown position units: cm

As mentioned before, the units for the images are all in cm…is this not allowed for online experiments? Moreover, could this be due to a mismatch cause by the fact that the experiment setting for “Screen” are in height?

cm can’t work online, because the browser doesn’t know the size of the monitor.

ScreenScale code | try it | discussion thread

Use to ask a participant to work out their screen scale relative to a credit card.
Morys-Carter, W. L. (2021, May 18). ScreenScale [Computer software]. Pavlovia. OSF | ScreenScale