Jump to content

Did R60 break ydata for matplotlib.pyplot?


Recommended Posts

I have a DataLab script that has worked until R60.  Now I get 

InvalidIndexError: (slice(None, None, None), None)

on the "plot" argument of matplotlib.pyplot.  I suspect the issue is that the format of the ydata argument has changed:

Lab_Pred_Fig = plt.figure(figsize=[20,10])
ax = Lab_Pred_Fig.add_subplot(1, 1, 1) 

ax.plot(xdata, ydata)

xdata is a simple list, but ydata is obtained from a spy.pull as shown here:


How do I fix this in R60?


seeq_plotbroker60_2023-06-05 at 4.05.51 PM.jpg

Link to comment
Share on other sites

I have a partial answer: this works

ax.plot(xdata, ydata["Lab_Opacity_PRED"])

Is there a better way?  I want to take the spy.pull signal and convert it to a list without having to specify the name of the attribute; just remove the timestamps.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...