Jul-20-2020, 06:50 AM
Hey, thank you for the help! Now that I'm trying to run the code, there seems to be an error in the function I've defined as gaussian
def gaussian(x, *param): y0, A1, w1, xc1 = param y = y0 + (A1/(w1*np.sqrt(np.pi/2)))*np.exp(-2*np.power((x-xc1)/w1, 2.)) return yIt returns an error at the y0, A1, w1, xc1 = param line:
ValueError: not enough values to unpack (expected 4, got 3)But to my understanding each value has been used in a function, and in higher gaussian fittings (two etc.) this seems to work perfectly fine.