Login Page - Create Account

Support Board


Date/Time: Mon, 16 Jun 2025 09:38:50 +0000



Post From: How to plot only the current hourly open as dash on a 5min chart

[2025-05-14 20:51:48]
John - SC Support - Posts: 40422
The idea of changing the 24 to 6 is a good thought, but not what you need to do.

Keep in mind how Sierra Chart (and most computers) keep track of time. A quick overview of how Sierra Chart in particular does it, is available here:
Spreadsheet Functions: Serial DateTime Values

Therefore, the formula we gave you is looking at the current hour and if the bar time matches that hour, then it displays the value, otherwise it does not. Therefore, you need to find a way to show the data for the previous 4 hours. The general idea would be to see if the current bar has an hour that is greater than or equal to the hour 4 hours ago.

We leave you with that to ruminate on and see if you can come up with the solution. The main part of this is relatively straightforward (well, for a programmer type), but what would be difficult is what to do when it is 1 or 2 in the morning, so you are dealing with resetting the time from 24 to 01 or 02. But you may not need to deal with that if you are never looking at data at that time.

If you work on this and can not come up with the solution, let us know. We will help you get to it. We just believe in the idea of "Give a person a fish and he eats for a day; teach a person to fish and they eat for a lifetime."
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing