I was given this part of the code, and although everything looks okay to me, there's a syntax error. This was the beginning of the code in this Jupyter Notebook.
I've tried changing the variables inside y_grid=np.zeros(HERE) to be other already defined variables, but that doesn't seem to work, and frankly didn't make sense to do, but I tried it anyways.
import numpy as np
import matplotlib.pyplot as plt
def lagrangeinterp(x_data,y_data,x_grid):
n=np.size(x_data)
n_grid=np.size(x_grid)
L=np.ones([n,n_grid]
y_grid=np.zeros(n_grid)
Here is my error message: y_grid=np.zeros(x_grid) ^ SyntaxError: invalid syntax