ipwidgets Interactive Charts in Jupyter Notebook

PHOTO EMBED

Sat Nov 26 2022 10:31:06 GMT+0000 (Coordinated Universal Time)

Saved by @janduplessis883 #decorators #jupyter

from ipywidgets import interact

@interact
def plot_polynom(a=[0,1,2,3], b=2):
    x = np.arange(-10, 10, 0.1)
    y = a*x**3+ b*x**2    
    plt.plot(x,y); plt.xlim(xmin=-10, xmax=10); plt.ylim(ymin=-100, ymax=100)
content_copyCOPY