Support Board
Date/Time: Sun, 24 Nov 2024 20:48:22 +0000
Color bar help
View Count: 299
[2024-04-23 21:10:19] |
User411320 - Posts: 289 |
attached is a picture showing a subgraph of a spreadsheet formula I'm working on. How would I go about coloring bars whenever the line crosses and closes above the 0.200 line? thanks
|
Screenshot 2024-04-23 170604_.png / V - Attached On 2024-04-23 21:10:08 UTC - Size: 9.15 KB - 64 views |
[2024-04-23 21:18:11] |
John - SC Support - Posts: 36238 |
Use the following formula for the alert in the "Color Bar Based on Alert Condition" study: ID1.SG1 > 0.2 Where ID1 is the ID of the study that draws the line and SG1 is the subgraph of the study that is the line. Refer to the following: Color Bar Based on Alert Condition For the most reliable, advanced, and zero cost futures order routing, use the Teton service: Sierra Chart Teton Futures Order Routing |
[2024-04-24 13:08:49] |
User411320 - Posts: 289 |
Thank you
|
[2024-04-24 18:54:34] |
User411320 - Posts: 289 |
so the formula worked, but it's not coloring the bar past this week no matter how much bar I put to color
|
Screenshot 2024-04-24 145219.png / V - Attached On 2024-04-24 18:54:22 UTC - Size: 81.15 KB - 66 views Screenshot 2024-04-24 145403.png / V - Attached On 2024-04-24 18:54:29 UTC - Size: 50.87 KB - 67 views |
[2024-04-24 20:26:44] |
User411320 - Posts: 289 |
Also how can I color a bar whenever it closes above or below the 0 line? just the 1 bar
|
[2024-04-24 23:11:34] |
John - SC Support - Posts: 36238 |
so the formula worked, but it's not coloring the bar past this week no matter how much bar I put to color
Did you change the formula to be the ID and Subgraph for your study? ID1 and SG1 are just examples. You need to change these for your setup. Also how can I color a bar whenever it closes above or below the 0 line? just the 1 bar
We are not understanding this. It will always close either above or below the 0 line (the chances of the studies that you are showing in your image, having a value of exactly 0 are very slim). Are you wanting different coloring for above zero than below zero? And what do you mean by "just the 1 bar"? For the most reliable, advanced, and zero cost futures order routing, use the Teton service: Sierra Chart Teton Futures Order Routing |
[2024-04-25 12:04:13] |
User411320 - Posts: 289 |
Hello John, Did you change the formula to be the ID and Subgraph for your study? ID1 and SG1 are just examples. You need to change these for your setup.
Yes I changed the formula, please see attached photos. We are not understanding this. It will always close either above or below the 0 line (the chances of the studies that you are showing in your image, having a value of exactly 0 are very slim). Are you wanting different coloring for above zero than below zero?
And what do you mean by "just the 1 bar"? Sorry, I'll try to explain better. I would like to color the bar of the exact candle that causes the study to close above or below 0. I've attached a photo with yellow vertical lines. In essence I would like the study to color those bars |
Screenshot 2024-04-25 075435.png / V - Attached On 2024-04-25 11:56:04 UTC - Size: 25.26 KB - 46 views Screenshot 2024-04-25 075502.png / V - Attached On 2024-04-25 11:56:11 UTC - Size: 33.07 KB - 51 views |
[2024-04-25 12:04:32] |
User411320 - Posts: 289 |
File attached
|
Screenshot 2024-04-25 080258.png / V - Attached On 2024-04-25 12:04:25 UTC - Size: 42.25 KB - 63 views |
[2024-04-25 15:02:11] |
John - SC Support - Posts: 36238 |
With regards to the bars that are being colored (or not being colored going back), we see that you have the "Numbers of Bars to Calculate" set to 1000. Try increasing this to get colored bars further back in time. With regards to the other question, the image you provided is basically asking to color the bar when the study value is 0. In order to overcome floating point errors and the fact that the result may not be exactly zero, you would want to test a small range of data around zero. So you would use a formula like the following: =AND(ID1.SG1 > -.01, ID1.SG1 < .01) This will give you a true result when the value of that subgraph at that bar is between 0.01 and -0.01. For the most reliable, advanced, and zero cost futures order routing, use the Teton service: Sierra Chart Teton Futures Order Routing |
[2024-04-25 20:37:14] |
User411320 - Posts: 289 |
Hello John, So I set the bars to calculate to 5000 and still won't go past yesterday. The formula you gave worked and oddly enough it colors bars past yesterday |
[2024-04-25 21:39:27] |
John - SC Support - Posts: 36238 |
Get us the chart where you are having the issue with it not drawing further back and we'll take a look. Follow these instructions to get us the chart: Support Board Posting Information: Providing Chartbook with Only a Single Chart 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: