Testing Whether a Drawing Indicator Repaints After Full Recalculation
Summary
The document presents a method for measuring whether a chart indicator changes marks it previously drew on closed bars. It defines repainting as a change to an existing object’s position, color, text, or continued presence after the bar has closed. The test seeds a custom symbol with historical data, records the indicator’s drawing objects, appends additional bars, and forces a full recalculation. Objects from the earlier pass are then matched and compared by anchor time, anchor price, color, and text over repeated steps.
Changes and disappearances are counted separately, and a run with no comparisons is treated as inconclusive. The author recommends lifting object history caps, allowing enough settling time, and deliberately introducing a known defect to confirm the harness detects it. The method targets bugs that can appear when object identifiers depend on bar indices. It does not assess whether an indicator is accurate or profitable, and results depend on configuring the test and exclusions correctly.
Key ideas
- The test checks whether drawing objects on closed bars change after more history is added and the indicator is rebuilt.
- It compares object anchors, colors, and text, while reporting changes separately from disappearances.
- A run with no comparable objects is inconclusive rather than evidence of a pass.
- The method is designed to expose issues such as object names tied to shifting bar indices.
- The test measures repaint behavior only and does not evaluate signal accuracy or trading performance.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.