matplotlib / matplotlib/mplfinance

How to add figure legend for "mpf.make_addplot" or "hlines"?

Open
#229 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

question
Dominant language
Python
Stars
4.4k
Forks
678
PR merge metrics
No merged PRs in 30d

Description

Hello,
I haven't found any example for adding figure legend. If I have a lot of plots generated from "mpf.make_addplot" or "hlines", how can I add the figure legend? Thank you!

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the question with mpf.make_addplot and hlines, then inspect how the generated Matplotlib figure handles legend entries. Determine whether the project needs usage guidance or an example, and consider the work complete when a documented approach covers multiple addplots and hlines.

Written by the indexing model from the issue text.

Assessment

Tech stack
matplotlib, python
Domain
data-visualization
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.