Python Forum
xlsxwriter + mplfinance: Plot Stock Chart in Excel Worksheet
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
xlsxwriter + mplfinance: Plot Stock Chart in Excel Worksheet
#1
Hello,

I would like to loop into various of instrument tickers in a dataframe and plot each instrument chart into an Excel worksheet.

Is there a possibility to do that on-the-fly using xlsxwriter's "insert_image" and mplfinance's "plot" functions?

The loop looks as follows:

for ticker in ticker:
	workbook.add_worksheet(ticker) # Add multiple sheets for each instrument
	filt2 = (dfInit["Ticker"] == ticker)
	mpf.plot(dfInit[filt2], title = ticker, type = "candle", style = "classic")  # This line have to be modified in order to insert charts into excel worksheet


Thank you in advance!
Reply


Messages In This Thread
xlsxwriter + mplfinance: Plot Stock Chart in Excel Worksheet - by KMV - Mar-09-2021, 05:34 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Create simple live plot of stock data dram 2 2,943 Jan-27-2023, 04:34 AM
Last Post: CucumberNox
  Create Excel Line Chart Programmatically dee 3 1,212 Dec-30-2022, 08:44 PM
Last Post: dee
  Changing the initial worksheet name in an MS Excel file azizrasul 3 982 Oct-02-2022, 07:56 PM
Last Post: azizrasul
  Sample labels from excel file in order to put them on x-axis and y-axis of a plot hobbyist 11 4,427 Sep-14-2021, 08:29 AM
Last Post: hobbyist
  Xlsxwriter: Create Multiple Sheets Based on Dataframe's Sorted Values KMV 2 3,521 Mar-09-2021, 12:24 PM
Last Post: KMV
  Python Matplotlib: Create chart for every 4 columns in Excel file JaneTan 2 2,804 Feb-28-2021, 05:02 AM
Last Post: JaneTan
  How to plot intraday data of several days in one plot mistermister 3 2,935 Dec-15-2020, 07:43 PM
Last Post: deanhystad
  xlsxwriter in windows dfstrottersfan 2 2,357 Sep-23-2020, 11:41 AM
Last Post: dfstrottersfan
  How to plot gantt chart using matplotlib Mekala 1 2,661 Jul-16-2020, 07:21 PM
Last Post: Marbelous
  Write tables from Word (.docx) to Excel (.xlsx) using xlsxwriter jackie 1 3,221 May-27-2020, 11:47 PM
Last Post: mcmxl22

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020