I am working on building an indicator to plot zones for a given day that are read from a file that matches the instrument + date stamp. See attached screenshot of the general idea of how I would imagine the plots to look.
I planned on using Draw.Region since it seemed to handle historical and future plots. Each day is expected to be a separate region. I don't want any interconnected lines between different days zones. My understanding of the documentation for Region is that if I supplied a unique tag a new region would be created otherwise the existing region with the same tag would be modified.
I am seeing behavior that leads me to think my understanding of the above is incorrect or my usage is incorrect (See overlapping_zones.png):
- Subsequent day's zones all start from the first day's zones. Note that the opacity increases and that Day 2's zones have a red border and start from Day 1.
- Zones connect in the midst a missing day (Day 3)
I now suspect that using ISeries to store the data is what is causing all the regions to start from the first bar plotted.
Code here for syntax highlighting: https://pastebin.com/Lb7Y5wP1
--Ryan
Comment