Evolving Daily High, Low and Mid price
Forums › ProRealTime English forum › ProBuilder support › Evolving Daily High, Low and Mid price
- This topic has 7 replies, 4 voices, and was last updated 1 year ago by mathiasKN.
Viewing 8 posts - 1 through 8 (of 8 total)
-
-
01/02/2021 at 4:54 PM #15599101/02/2021 at 5:25 PM #155996
There you go:
12345678IF IntraDayBarIndex = 0 THENDailyHigh = highDailyLow = lowENDIFDailyHigh = max(DailyHigh,high)DailyLow = min(DailyLow,low)DailyMid = DailyLow + ((DailyHigh - DailyLow) / 2)RETURN DailyHigh AS "Dhigh",DailyLow AS "Dlow",DailyMid AS "Dmid"01/02/2021 at 5:39 PM #155997..or look here:
https://www.prorealcode.com/topic/customized-trading-session/
01/02/2021 at 6:38 PM #15600405/31/2023 at 6:11 PM #215516Possible to add specific market hour into the script you posted <span class=”bbp-author-name”>robertogozzi</span>?
BR
Mathias06/01/2023 at 1:01 AM #215522Yes, you have to set both the StartTime and EndTime (not tested):
123456789101112131415161718192021222324252627ONCE StartTime = 090000ONCE EndTime = 170000ONCE DailyHigh = 0ONCE DailyLow = 0ONCE DailyMid = 0IF EndTime >= StartTime THENIF (OpenTime >= StartTime) AND (OpenTime <= StartTime) THENIF (OpenTime = StartTime) OR ((OpenTime > StartTime) AND (OpenTime[1] < StartTime))DailyHigh = highDailyLow = lowENDIFDailyHigh = max(DailyHigh,high)DailyLow = min(DailyLow,low)DailyMid = DailyLow + ((DailyHigh - DailyLow) / 2)ENDIFELSEIF (OpenTime >= StartTime) OR (OpenTime <= EndTime) THENIF (OpenTime = StartTime) OR ((OpenTime > StartTime) AND (OpenTime[1] < StartTime)) OR ((OpenTime > 000000) AND (OpenTime[1] > OpenTime)) THENDailyHigh = highDailyLow = lowENDIFDailyHigh = max(DailyHigh,high)DailyLow = min(DailyLow,low)DailyMid = DailyLow + ((DailyHigh - DailyLow) / 2)ENDIFENDIFRETURN DailyHigh AS "Dhigh",DailyLow AS "Dlow",DailyMid AS "Dmid"06/01/2023 at 1:03 AM #215524Do not double post. Ask your question only once and only in one forum. All double posts will be deleted anyway so posting the same question multiple times will just be wasting your own time and will not get you an answer any quicker.
Double posting just creates confusion in the forums.
Thank you 🙂
06/02/2023 at 3:34 PM #215591 -
AuthorPosts
Viewing 8 posts - 1 through 8 (of 8 total)
Find exclusive trading pro-tools on
Similar topics: