matplotlib / matplotlib/mplfinance

Unable to prevent plot from initial display

Open
#441 1 comment 0 reactions 0 assignees View on GitHub
question
Dominant language
Python
Stars
4.4k
Forks
678
PR merge metrics
No merged PRs in 30d

Description

Hi,

I am trying to create a plot object which will later be used in a report. I am able to create the plot and store as object in a variable:

`plot = mpf.plot(data.iloc[::5, :], type='line', volume=True, figratio=(15, 7), style='binance', title=ticker, closefig=True, returnfig=True)[0]`

However, the plot shows on my windows screen initially as a small box, then the chart, then closes immediately. Because I am running the code in a loop, many windows appear and eventually errors out from memory consumption, plus it is a bit cumbersome to have the windows appear in the first place.

Thanks for any help! :)

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the reported mpf.plot call with data.iloc[::5, :], volume=True, closefig=True, and returnfig=True in a loop on Windows. Inspect how these options interact with the initial display and confirm that creating plots for a report no longer opens transient windows or exhausts memory.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.