1

I have to lists of that kind (series and pred_upd):

enter image description here

I try to put them together on a plot doing that:

az = series.plot(figsize=(12,8), label='o')
ax = pred_upd.plot(style='r--', label='Dynamic Prediction');
ax.legend();
az.legend();
plt.plot()
plt.show()

I receive error:

-> 2417         if isinstance(data, DataFrame):
   2418             if x is not None:
   2419                 if com.is_integer(x) and not data.columns.holds_integer():

TypeError: isinstance() arg 2 must be a type or tuple of types

What I do wrong?

1 Answer 1

2

If you are using matplotlib, I think you are using it incorrectly. I cannot really infer what type are the variables series and pred_upd are, but I am assuming they are of type list (from your example).

To use matplotlib:

import matplotlib.pyplot as plt
plt.plot(series)
plt.hold(True)
plt.plot(pred_upd)
plt.show()

You can put some parameters in there - but that should be the format.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.