I’m testing out pymatgen to see if I can use it for my purposes. The following is my complete code:
from pymatgen.analysis.pourbaix_diagram import PourbaixDiagram, PourbaixPlotter
from pymatgen.ext.matproj import MPRester
# Initialize the MP Rester
mpr = MPRester(MP_API_KEY)
entries = mpr.get_pourbaix_entries(["Al"])
# Construct the PourbaixDiagram object
pbx = PourbaixDiagram(entries)
plotter = PourbaixPlotter(pbx)
plotter.get_pourbaix_plot().show()
Running the code generates the following error:
Exception has occurred: AttributeError
'Axes' object has no attribute 'show'
plotter.get_pourbaix_plot().show()
AttributeError: 'Axes' object has no attribute 'show'
I was wondering if someone could point me to the right direction on how to fix this. Thanks!