Login Page - Create Account

Support Board


Date/Time: Tue, 26 Aug 2025 11:54:21 +0000



[Programming Help] - I want to know a formula

View Count: 883

[2025-02-08 09:51:43]
JabDouks25 - Posts: 22
Hello there,

I would like to add a formula, in my footprint (renko 5T) for the ES.

I would like to use the color bar based on Alert condition studie to highlight aborption of a level; I managed to show (divergences, both volumes and delta) using this studie. But i might say that I have some difficulties programming in order to show this condition:

Buyer Absorbed ( Delta >0 (a least 300), and the next bar is closing down the previous one (red candle on the renko)
Seller Absorbed (Delta <0 (a least 300), and the next bar is closing up the previous one (green candle on the renko)

i would like to know if it is possible to filter it by only putting the important ones only, what kind of multiplier factor can I put to make it clear.

I hope, i have been clear on my request (sorry, english is my third language)
[2025-02-10 15:17:39]
John - SC Support - Posts: 41464
The only trick to this is how you determine that the next bar is closing up or down. For Renko, there are special Open and Close values, so you need to use those in this case. Refer to the following:
Renko Bar Charts: Renko Open, High, Low, Close Values

Therefore, your Alert Condition would look like the following:
=AND(ID1.SG1[-1] > 300, ID0.SG22 > ID0.SG23)

Where ID1 is the ID of the study where you get the Delta from, SG1 is the subgraph that has the delta in the study from which you get the delta, [-1] indicates to use the next to last bar for this data, ID0.SG22 is the Renko Open, and ID0.SG23 is the Renko Close.

Refer to the following:
Study/Chart Alerts And Scanning: Referencing Other Studies on the Chart

Study/Chart Alerts And Scanning: Referencing Data Other Than on the Last Bar/Column In the Chart
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-02-13 15:27:26]
JabDouks25 - Posts: 22
Hi John,

Thank you for your time and support, i will try that and get back to you if needed;

Best Regards
[2025-05-31 08:01:16]
JabDouks25 - Posts: 22
Hello,

I have another issue, because, i am always trying to improve my FP renko 5T.

I am trying to code with (color bar based on alert condition) a delta tails with the following conditions:

For a Buying Delta Tails (Delta<0 at the very bottom of the bar, total delta of the bar > 0, and a bearish bar)

=AND(C < O, ID1.SG45 < 70, ID1.SG1 > 0)

For a selling delta Tails (Delta>0 at the very top of the bar, total delta of the bar < 0, and bullish bar)

=AND(C > O, ID1.SG46 > 70, ID1.SG1 < 0)

I have satiying results with that formula, but i am not sure if I used the right subgraph to determine accuratly the top and the bottom of the bar within my formula; (see the attached document)

Can you help me figure this out please?

Thank you for your time.
imagefpbarre.jpg / V - Attached On 2025-05-31 07:59:02 UTC - Size: 64.94 KB - 136 views
Attachment Deleted.
imagefpbarre.jpg / V - Attached On 2025-05-31 08:00:16 UTC - Size: 64.94 KB - 125 views
[2025-06-02 13:37:27]
John - SC Support - Posts: 41464
What study is ID1 and what are SG1, SG45, and SG46 of that study?
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-06-02 14:24:54]
JabDouks25 - Posts: 22
Hello,

ID1 (Number Bars calulates Values with delta stats) SG1 (DElta - Ask Volume Bid Volume Difference)

ID39 tNumber bars calculated values), SG45: Low bid Volume percent) and SG46 ( High Ask Volume percent)

I need to find the best subgraph to fin the top and the bottom of the bar if possible.

Thank you for your time
[2025-06-02 16:07:06]
John - SC Support - Posts: 41464
The Alert conditions allow you to access the Total Volume, Bid Volume, and Ask Volume at each price level within a bar. Refer to the following:
Study/Chart Alerts And Scanning: Special Functions

Therefore, to get the delta (ask - bid) at the highest price point in the bar, you would use the following formula:
=AVAP(H, 0) - BVAP(H, 0)

And to get the same thing at the Low, you change the H for an L and get the following:
=AVAP(L, 0) - BVAP(L, 0)

So your total formula would look like the following:
=AND(C < O, AVAP(L, 0) - BVAP(L, 0) < -70, ID1.SG1 > 0)
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-06-02 17:17:01]
JabDouks25 - Posts: 22
your are the boss, thank you for your support and you fast response, i will try that and come back to you if needed

best regards
[2025-06-08 14:05:07]
JabDouks25 - Posts: 22
Hello,

I am looking for the best study to try to calculate in real time the average of some values (in my case, both delta and volume), starting from the Open US (9h30 EST to the closing)

I need to know if my structure is ok?

(i use study average)

AND(ABS(ID1.SG1) > ABS(ID39.SG1) * 1.5,TIME > 153000,TIME < 215900)
ID1.SG1 is my delta
ID39.SG1 is the average calculated from the study average

Thank you for your time
[2025-06-09 16:13:21]
John - SC Support - Posts: 41464
The way you are referencing time is not correct. You need to use the BARTIME() function for the time of the bar, and also use the TIME() function to specify the actual time you want to test against. For instance, to check if a bar is after 15:30, you would use the following:
=BARTIME > TIME(15, 30, 00)

Refer to the following:
Study/Chart Alerts And Scanning: Available Main Price Graph Identifiers/Variables

https://www.sierrachart.com/index.php?page=doc/SpreadsheetFunctions.html#TIME_Function
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-06-10 14:54:52]
JabDouks25 - Posts: 22
Ok, thank you, it works a lot better with the right study.

I would like To highlight those crucial informations directly on NBCV (Number Bars Calculated Values), in my case It will be the Delta stat.

I would like to know if it is possible to directly change the color of my informations when my study calculated a High delta or/and High Volume. (on the study, not on the grph°, i already have to many information

is that Possible?
[2025-06-10 15:57:21]
John - SC Support - Posts: 41464
there is not a way to highlight the cell of the Numbers Bars Calculated Values study based on an alert condition. The only coloring options are what is available within the study itself.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-06-18 17:24:08]
JabDouks25 - Posts: 22
Thank you for your answer,

this is the formula I come up with to calculate the average of the vaolume in order to have a signal that highlight a pike of volume.

Can you give your thoughts about it?

AND(ID1.SG13>ID40.SG1*1.5, BARTIME>TIME(15,30,00))

ID1.SG13: Volume from delta stat (main grpah)
ID40.SG1: Volume Average using Study subgraph averagz.

Thank you for your answer
[2025-06-18 18:08:23]
John - SC Support - Posts: 41464
This seems fine in terms of ID1.SG13 is greater than ID40.SG1*1.5. We are not certain why you have the check to see if the bar is after 15:30:00 - as this means you will only get an alert for bars that are created between 15:30:00 and 23:59:59. If that is what you want, then this is fine.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-06-19 15:25:23]
JabDouks25 - Posts: 22
ok, thank you for your time.

I am only interested in the volume wich occurs starting the Open US (I am based in europe so 15h30 is the time of the open)

what happens in pre market is not relevant in my system.

best regards
[2025-06-22 11:58:54]
JabDouks25 - Posts: 22
Hello, i come back to you, because i suceefully with your help putting alert messages when the volume are increasing tremendsouly when compared with the average of volume since the open.

I come with a problem when it comes with the delta since the open us. I am trying to calculate the averages of posive deltas since the open and compare it with the current delta in order to highlight a signicant increase of it.

here what i achieved so far: ID1.SG1 : Delta

use spreedsheet formula: with that condition: =IF(AND(ID1.SG1 > 0, BARTIME > TIME(15,30,00)), ID1.SG1, 0) -> Result: ID31.SG1.

then I use study subgraphs average : ref: ID31.SG1 -> result: ID39.SG1.

Then i create a signal with color bar based with: =AND(ID1.SG1 > ID39.SG1 * 1.2, BARTIME > TIME(15,30,00))

what would be the best study to get what I need, which is to highlight a significant increase of the delta (Positive: agression of the buyers), and negative (agression of the sellers)

I am not really having much of a progress here.

thank you for your help
[2025-06-23 15:08:58]
John - SC Support - Posts: 41464
What exactly are you looking for in terms of an increase in the delta? How are you wanting this in relation to the average?

Since you are dealing with multiple steps to get what you want, you might be better off using the "Spreadsheet Study" rather than the Spreadsheet Formula. Refer to the following:
Using the Spreadsheet Study
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-06-29 09:59:29]
JabDouks25 - Posts: 22
Hello,

What I am trying to achieve is to highlight in my footprint (using the right study), a significant increase of the delta in the current bar.

For instance, I have an average delta of +100 since the open, if the delta pikes at +500(or more) in the current bar, it gives a signal that byers are agressive (not necessarly an entry), but an information that at this price level, something is happening.

Same thing with the sellers, I need to see without calculating in reel time an significant entry of agressive sellers at different prices, that i can analyse within my system.

I hope, i have been clear, (English is a thrid language)

thank you for your time.

Regards
[2025-06-30 14:12:42]
John - SC Support - Posts: 41464
If you want to test if the delta is more than 1.2 times greater than the average, then the formula you wrote here is correct:
=AND(ID1.SG1 > ID39.SG1 * 1.2, BARTIME > TIME(15,30,00))

The only "trick" is that if you are using this with the "Color Bar Based on Alert Condition" on a "Numbers Bars" study, then you can not use the default Draw Style of "Color Bar" as there is no bar to actually color. You would need to use some other Draw Style, such as "Point on High", which will then show when the condition is true. Refer to the following:
Color Bar Based on Alert Condition: Drawing Arrows/Text or Other Styles at the High or Low of Bars
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