0

I need to create interactive chart, on which a line can be slided right/left on x axis while saving new values.

Illustration: I have the right red line in the A position but want to move it to B position (orange line) manually and then save position B to a list. what i need to do with a chart picture

I was looking at ipywidgets like the code below, but, for now, it does not seem to be helpful for my task, does it?:

from ipywidgets import interact, interactive, fixed, interact_manual 
import ipywidgets as widgets

def f(x):
    plt.plot(np.arange(0,10), x*np.arange(0,10))
    plt.ylim(-30,30)
    
interact(f, x=10)

Please advise

0 Answers0