If I run
import pandas as pd
import mpld3
import seaborn as sns
df = pd.DataFrame([(1,3),(2,-1)],columns= ['a','b'])
plt.figure(figsize=(5,5))
sns.regplot('a', 'b', df)
works fine. If I add
mpld3.enable_notebook()
I obtain error: Object of type 'ndarray' is not JSON serializable
Do you have any suggestion about what is causing this annoyance with mpld3?
For what I can understand, this is not the same question asked in NumPy array is not JSON serializable In my question I'm asking how to make mpld3 work or at least not making everything else not working.