Optuma Forums › Optuma Scripting › Breadth Engine: Percent of stocks below a date › Reply To: Breadth Engine: Percent of stocks below a date
May 9, 2022 at 8:39 am #68154
- Topics: 5
- Replies: 670
- Posts: 675
BARDATE() returns an index value. So March 8 for example returns a value of 44,628. Rather than having to know and find that index value, STRDATE() converts that into a standard format of yyyy-mm-dd.
So V1 you select the date you are after.
V2 sets a BARINDEX value for all bars.
V3 says, when the BARINDEX value matches the selected date (March 8) show us the Closing value for that bar.