matplotlib / mplfinance

Financial Markets Data Visualization using Matplotlib
https://pypi.org/project/mplfinance/
Other
3.48k stars 613 forks source link

add vcedge to `make_marketcolors()` #670

Open kootsZhin opened 1 month ago

kootsZhin commented 1 month ago

Not sure if it was intended but currently vcedge which sets the edge colors for volume bars is missing from make_marketcolors() and as a results, the results with inherent=True is different from the example notebook.

Example

The below example replicate the notebook example with the same usage code.

mc = mpf.make_marketcolors(up='#00ff00',down='#ff00ff',inherit=True)

s = mpf.make_mpf_style(base_mpf_style="nightclouds", y_on_right=True, marketcolors=mc)

mpf.plot(df, title=f"\n{symbol}", type='candle', volume=True, style=s, ylabel="", ylabel_lower="")

Before adding vcedge (currently)

fa6ef90e-948a-4819-a736-bacc150369a9

After adding vcedge

0992f6c4-99a5-4866-bb80-6158c7d58d9b