I have this dataframe:
where:
x: independent variable
y: independent variable
z: dependent variable
How do I find in Python the optimal "a" and "b" parameters , so that I optimize this function:
z = a*sin(x) + b*sin(y)
I know that the optimal solution is:
a = 0
b = 1
But what Python code should I use? I guess I should use scipy optimize, but I am only able to use it with one independent variable.

df.to_records())