Login Page - Create Account

Support Board


Date/Time: Fri, 07 Feb 2025 15:21:52 +0000



Color based on alert condition

View Count: 111

[2025-01-02 20:40:40]
Magnum Trades - Posts: 6
Hi I’m trying to color bar based on a study I use in Sc. I’m using she custom study Delta momentum.ID10,SG4. I am able to have bars color as I want. I was on seeing if there is a way to use this study with a threshold for example. My alert reads as follow. =ID10,SG4>-400. It would color bar red. Is there a way to say to write the alert to say ID10,SG4>-400 but less than -450. What I’m trying to accomplish is a gradient type coloring of bars. For example -300 but less than -350 color bar this color. -350 but less than -400 color bar this color etc etc
[2025-01-02 20:55:02]
John - SC Support - Posts: 37810
To start with, to only have the bar colored between -400 and -450 your alert condition would be the following:
=AND(ID10.SG4 < -400, ID10.SG4 > -450)

In order to have multiple colors, you would need multiple copies of the "Color Bar Based on Alert Condition".

Also, be careful with your signs. Your original condition of "=ID10.SG4 > -400" is going to color the bar for any value greater than -400 (so from -400 and up towards zero and then anything above zero).

And we are not sure if it was a typo, but your condition has a comma instead of a period (=ID10,SG4 instead of =ID10.SG4). Make sure you have this correct or things will not work.
For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-01-02 21:32:58]
Magnum Trades - Posts: 6
Thanks and yes that was a typo I had the greater than and less than signs backwards and it is a period instead of comma. I just tried the condition you gave me and now the bars that were colored are not any more. I tired different numbers to try to get them to reappear but nothing appears
[2025-01-03 15:14:51]
John - SC Support - Posts: 37810
Do those bars actually have a value between -400 and -450?

You would need to work through the troubleshooting to see what is occurring. Start by removing the AND() and just use one condition (=ID10.SG4 < -400) and expand from there.
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