Alleleplot -> AttributeError: module 'matplotlib.pyplot' has no attribute 'array'

36 views
Skip to first unread message

space.a...@gmail.com

unread,
Apr 1, 2020, 7:33:59 AM4/1/20
to Inspyred
I'm getting this error when I try to plot the individuals file 

  File "main.py", line 64, in <module>
    main(display=True)
  File "main.py", line 54, in main
    inspyred.ec.analysis.allele_plot('inds.csv')
  File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/inspyred/ec/analysis.py", line 249, in allele_plot
    plt.pcolor(plt.array(plot_data))
AttributeError: module 'matplotlib.pyplot' has no attribute 'array'

Aaron Garrett

unread,
Apr 1, 2020, 1:03:30 PM4/1/20
to Inspyred
My guess is that Matplotlib changed their API and you're using a newer version that doesn't have that array function. You can probably copy that code from the inspyred source and change plt.array to numpy.array to make it work for you. I haven't tested that, though.

--
Aaron Garrett



--
You received this message because you are subscribed to the Google Groups "Inspyred" group.
To unsubscribe from this group and stop receiving emails from it, send an email to inspyred+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/inspyred/d6bf4b31-08e2-443e-b834-ecc4a98ab5c0%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages