kernc / kernc/backtesting.py

Plotting time axis misplaced

Open
#284 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Python
Stars
9k
Forks
1.5k
PR merge metrics
No merged PRs in 30d

Description

I'm watching a misplaced time axis for 1min OHLC candles.
As seen in the image below, the minutes of the time axis do not match with that of the tooltip.

Actual Behavior
Screen Shot 2021-03-20 at 13 19 03
Steps to Reproduce
bt = Backtest(1minute_ohlc_candles, Strat)
bt.plot(plot_equity=True, superimpose=False, show_legend=True, plot_return=False, plot_drawdown=False)
  • Backtesting version: 0.3.1

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

Reproduce the issue with the provided 1-minute OHLC candles and the Backtest.plot() call, then trace the plotting and tooltip time-axis handling. Done means the chart's minute labels align with the tooltip times for this case, with no regression in the other plot options shown.

Written by the indexing model from the issue text.

Assessment

Tech stack
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.