URL of experiment: https://gitlab.pavlovia.org/kennethj/variable-interval
Description of the problem: I’ve created an experiment in Builder that includes a Code Component. The code I am struggling with is as follows: VI = normal(loc=20, scale=10.0)
I need to randomly sample numbers, with a specified mean (loc) and standard deviation (scale), from a normal distribution. The Code Component works in Builder, but does not work online (i.e., I get an error that ‘normal’ is not defined). Auto->JS does not know what to do with ‘random.normal’ and I do not know how to translate it to JS.
Does anyone know how to translate this code to JS?