Skip to content

AttributeError: 'Legend' object has no attribute 'legendHandles' #12

@JasonGross

Description

@JasonGross

" for i in range(len(legend.legendHandles)):\n",

gives
AttributeError: 'Legend' object has no attribute 'legendHandles'

My version of matplotlib is

% pip list | grep matplot
matplotlib                 3.9.1
matplotlib-inline          0.1.7

https://github.com/matplotlib/matplotlib/blob/42b88d01fdd93846d925b1097167d36ea31c7733/doc/api/prev_api_changes/api_changes_3.9.0/removals.rst?plain=1#L147
claims it was removed in 3.9.0 and legend_handles should be used instead

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions