Login Page - Create Account

Support Board


Date/Time: Thu, 06 Feb 2025 14:55:38 +0000



[Programming Help] - Indicator/Study Setup - Drawing levels based on High/Low Input

View Count: 1365

[2020-04-08 18:11:16]
User236528 - Posts: 3
Hello. I appreciate the assistance you provide when needed. I have a specific question to part of a strategy I trade an looking for assistance into getting these levels (lines) built into my chart.

I focus on the 30 second opening range on the ES and Crude. To do this I have a 30 sec bar chart and then it puts the High/Low for time period at those levels. I have it run from 8:30am CT until the next days session for ES and 8am for Crude. Essentially establishing that opening range.

From here I calculate what that range is (x). Then I look at what the levels for that x would be @ 1:1, 2:1, 3:1, and 4:1 levels are above and below the range. Those would be trading targets if you were to be long above opening range or short below the opening range. Essentially I want to look to automating this but what I want to setup is the following.

Once the Opening range is established in the first 30 seconds. I would like to have those levels of 1-4x established above and below. Then have it automatically repeat each day on the new 30s opening range. Once that is created I can go in and change the line style and colors, but want it extending as to the right to the next days open. That way I can easily look at a chart and know those targets and look at the end of the day if they are hitting targets around the open.

Are you able to point me in the direction of coding this or code it for me? I do not think it is difficult to do but never have done it.

I appreciate any help you can provide. Thank you for your continued support.

Examples of entries today (range and then the targets). I add 2 ticks as entry would be one tick out of range and then stop would be another tick.

ES  
30 s High  2685.00
30 s Low  2676.75
Range  8.25
Range + 2 ticks  8.75
Stop - pts  8.75
p1  8.75
p2  17.50
p3  26.25
p4  35.00
  
Long Entry  2685.25
Stop  2676.50
P1  2694.00
P2  2702.75
P3  2711.50
P4  2720.25
  
  
Short Entry  2676.50
Stop  2685.25
P1  2667.75
P2  2659.00
P3  2650.25
P4  2641.50
[2020-04-08 18:54:19]
Sawtooth - Posts: 4170
Take a look at the Initial Balance study. It has extension line multipliers, and they extend until the following day.

I notice that your entry is one tick outside of the range, and your extensions use the range plus 2 ticks beyond the one tick entry outside of the range. If this is intended, you can't use the extension line multipliers of the Initial Balance study because the offsets would need to be calculated.

The easiest way to calculate and plot 10 lines is to use a single instance of the Spreadsheet Study study that references the output of the Initial Balance study.
[2020-04-28 21:47:19]
User19107 - Posts: 7
User236528 - did you get this working? I'm trying something similar and would like to collaborate.
[2020-04-29 00:18:45]
User236528 - Posts: 3
i did get a solution to do essentially what i wanted through the initial balance indicator with extension lines. it doesn’t calculate for the extra tick i was looking for but takes opening range calculation i want then extension lines above and below with that same range.
[2020-04-29 02:25:55]
User19107 - Posts: 7
Did you do that through applying a study to the chart or actually in the ASCIL code?

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

Login

Login Page - Create Account