On 2022-05-29 13:57, iMath wrote:
please see the formated code at 
https://stackoverflow.com/questions/72423464/matplotlib-basemap-colorbar-exception-given-element-not-contained-in-the-stack

The problem might be that you're passing "ax=self.ax" when you create the basemap, and you have:

    self.ax = self.map_canvas.figure.subplots()

According to the docs, ".subplots" doesn't return the axes, it returns a _tuple_ of the figure and the axes.
--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to