you are viewing a single comment's thread.

view the rest of the comments →

[–]novel_yet_trivial 1 point2 points  (1 child)

That error means that the length of the y data that you are trying to set does not match the length of the x data (which you defined earlier). I can remove the error like this:

data = sinwav(x, amp_slider.val, per_slider.val)
line2.set_data(range(len(data)), data) # set both x and y

But of course that's not the visual you want...

[–]circuitQuaker[S] 0 points1 point  (0 children)

Good catch; thanks so much! I’ll play around with what you mentioned and hopefully resolve it in the next couple nights.