Login Page - Create Account

Support Board


Date/Time: Thu, 27 Feb 2025 09:16:33 +0000



Post From: For time bars: function for num of bars per day, and num of bars since midnight?

[2021-06-24 00:27:54]
marcovth - Posts: 61
Hello ...

Kind of basic, but I couldn't find it ...

For time bars only: is there a sc.function for the number of bars per day (based on the settings), and a sc.function for the number of bars since midnight for a particular index?

(So if you give an index of a bar 3 days ago, the function will calculate the number of bars from midnight three days ago up to that particular index)

Anyway, my goal is to calculate the average volume for each same bar at the same time of each day. In other words, the average volume for a bar going back each day, indexed by the number of bars since midnight (or otherwise the first bar of the days).