I am unable to run the following code:
from gekko import GEKKO
# data to be spline to find maximum
x = [-1.0, -0.6, -0.2, 0.2, 0.6, 1.0]
y = [0.1, 5.0, 16.0, 17.0, 4.0, 0.2]
# gekko model
m = GEKKO()
x_gekko = m.Var()
y_gekko = m.Var()
m.cspline(x_gekko, y_gekko, x, y, True)
m.Maximize(y_gekko)
m.solve()
When this runs, I get the following error: 'GEKKO' object has no attribute 'Maximize'