kernc / kernc/backtesting.py

Auto-scale Y-axis for indicators graph when zooming

Open
#356 5 comments 1 reaction 0 assignees View on GitHub
enhancement
Dominant language
Python
Stars
9k
Forks
1.5k
PR merge metrics
No merged PRs in 30d

Description

Original Discussion Post: #355

There's something that I noticed which makes it difficult to view indicator graph on the chart if you're backtesting for longer period. Below is an example of an indicator view on the chart without zooming in. Notice the y axis scales.
Screenshot 2021-05-21 at 4 03 16 PM

Now, when I zoom in to focus on a specific period when ttm squeeze value stayed between -5 to +5, it still shows the full scale from -15 to+20. which makes it really hard to visualize the indicator chart. See below.
Screenshot 2021-05-21 at 4 09 25 PM

I know that re-scaling is allowed for the price chart/Volume. Is that something that can be implemented on the indicator charts as well?

Contributor guide

Open the contributing guide

Research direction

No file or test is named. Start by tracing the existing price-chart and volume rescaling behavior, then compare it with the indicator-chart zoom path. Reproduce the reported long-period zoom case; done means the indicator y-axis rescales to the visible range after zooming.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
data-visualization
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.