Skip to content

Error in examples/samplers/DEMetropolisZ_EfficiencyComparison.ipynb #731

Open
@williambdean

Description

@williambdean

Not working with matplotlib '3.9.2'

──────────────────────────────────── Error running examples/samplers/DEMetropolisZ_EfficiencyComparison.ipynb ────────────────────────────────────

---------------------------------------------------------------------------
Exception encountered at "In [18]":
---------------------------------------------------------------------------
KeyError                                  Traceback (most recent call last)
Cell In[18], line 1
----> 1 plot_forest_compare_analytical(results_df)

Cell In[12], line 41, in plot_forest_compare_analytical(results_df)
     39 labels = ax.get_legend().__dict__["texts"]
     40 labels = [label.__dict__["_text"] for label in labels]
---> 41 handles = ax.get_legend().__dict__["legendHandles"]
     42 ax.legend(
     43     handles[::-1],
     44     labels[::-1],
   (...)
     49     title="94% and 50% HDI",
     50 )
     51 ax.set_title(
     52     f"Comparison of MCMC Samples and Analytical Solutions\nFirst 5 Dimensions of {D} Dimensional Target Distribution"
     53 )

KeyError: 'legendHandles'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions