I want to mark some dates on the chart using the “Show Bar” tool.
Here is my script:
// Mark Dates on the Chart with Show Bar
Line1 = STRDATE(DATE=2022-02-10) ;
Line2 = BARDATE() == Line1;
Line3 = IF(Line2 == 1, High(), 0) ;
Line3
The script works as it should it marks the bar and if I set the property “Display” to “Number” it shows the high of the bar.
Now I want to display the date of the bar. Here is my script:
// Mark Dates on the Chart with Show Bar
Line1 = STRDATE(DATE=2022-02-10) ;
Line2 = BARDATE() == Line1;
Line3 = IF(Line2 == 1, BARDATE(), 0) ;
Line3
The script marks the bar BUT shows as the date the number “44.602”. Is there a way to display the date of the bar?
Another question: Is it possible to select a bar and display the high or low and the date of the bar as it is possible with the “Time Price Label” tool?
Currently the Show Bar doesn’t have support to show a date format. I’ll log a request with the developers to see if it is something we can include in a future update.
Just a reminder that my feature recommendation that the tool “Show Bars” should support the display of a date format (see above), is still on my wish list for a future update of Optuma.