Login Page - Create Account

Support Board


Date/Time: Tue, 26 Nov 2024 08:41:33 +0000



How to plot the developing weekly high and low without plotting the prior ones

View Count: 273

[2023-12-12 21:35:00]
A77 - Posts: 18
Hi,

Study is period OHLC and set to weekly with use current period set to Yes.

I get the developing high and lows just as I intended, but it also plots the prior week high and lows which is unfortunate because I already have studies for the prior week highs and lows and they overlap.

Is there a way to only plot the developing high and low but make sure it doesn't plot prior week H/L? the attached second chart just for illustration purposes (demonstrating that it does indeed plot the prior week H/L. In other charts the W high is overlapped with other studies and making the chart cluttered.

Any fix?
Thanks
imagesierra ex.png / V - Attached On 2023-12-12 21:28:41 UTC - Size: 51.05 KB - 67 views
Attachment Deleted.
imageex sierra.png / V - Attached On 2023-12-12 21:33:21 UTC - Size: 32.24 KB - 65 views
[2023-12-12 22:01:39]
John - SC Support - Posts: 36286
One partial solution is to set the Input for "Number of Days to Calculate" to "5" (or 6, depending on how your chart is setup), but this will still give you some of the information in the previous week.

The best solution would be to use the Spreadsheet Study to find the first bar for Sunday's trading (or whatever day/time you have set for the first trade for the week) and then use that Row information to get the data from the Period OHLC to specific columns in the Spreadsheet only to that row that you will then display (you would hide the original Period OHLC study).

For example, here is a quick test we did for this - you could make this better than what we did, we just wanted to make sure it would work:
- Cell K3: =IF(AND(WEEKDAY(A3) = 1, HOUR(A3) = 17, MINUTE(A3) = 0), ROW(A3), 0)
- Cell L3: =MOSTRECENTNONZEROVALUE(K3:K2000)
- Cell M3: =IF(ROW(A3) <= $L$3, ID1.SG1@3, 0)

This will give you the Open for the Period OHLC for just the current week in column M.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account