Login Page - Create Account

Support Board


Date/Time: Wed, 19 Mar 2025 16:58:23 +0000



Spreadsheet formula help!

View Count: 746

[2022-10-25 11:52:04]
User9890731 - Posts: 47
Hello,

I need help referencing an alert condition from a study on the main price chart. To put it simply I need a formula for when an alert condition is met ,say in (spreadsheet system for trading) cell k3- [=AA3<-3000] then at that price point on the chart (E3) that corresponds to the alert condition will then become the reference price point determining whether to enter or exit the trade depending on whether (E3) current price is above or below the price at which (AA3<-3000)...

So if I were to set a buy order condition,

then @cell k3 (=aa3<-3000) and (E3> the price the alert condition was true)

Hope it made sense.
[2022-10-25 13:23:35]
Sawtooth - Posts: 4186
In a Formula Column, create a persistent value of the price when the alert condition is TRUE (AA3<-3000), then in K3 compare it to the current price (E3)

Here are some examples of persistent variables for a spreadsheet study:
Spreadsheet Example Formulas and Usage: Persistent and Incrementing Variables
Spreadsheet Example Formulas and Usage: Return Last Two Zig Zag Reversal Values

...Like this, in P3:
=IF(AlertConditionTrue,E3,IF(ReleaseCondition,0,P4))
then in K3:
=AND(YourOtherEntryConditions,E3>P3,P3>0)

Notes:
-Create the persistent value with an event, then release it with another event, so it's ready for the next signal.
-It's not possible to capture an intrabar value, only a close-of-bar value, so the alert condition must be true at close-of-bar.
[2022-10-25 16:18:37]
User9890731 - Posts: 47
THE formula works, but i noticed that i keep getting multiple different price points at (P3) as the 3000 signals keeps getting hit multiple times giving me different E3 values, is there a way to edit the condition @P3 such that the price E3 remains the same from the initial signal until release condition is True so that i dont get multiple different values e3 before the release condition occurs.
[2022-10-25 17:09:10]
Sawtooth - Posts: 4186
is there a way to edit the condition @P3 such that the price E3 remains the same from the initial signal?
You would need to use a different release condition so that the initial signal remains persistent.

You might also need to modify the initial signal to isolate its unique condition.
[2022-10-26 08:50:28]
User9890731 - Posts: 47
I managed to isolate the signals on cell (P) to cell (S), so that other signals are ignored until the release condition is met. I now need another formula to identify P3 and S3 signals when true and display that price (P3) on every consecutive cell until new signal becomes true...

So if the formula is on cell R3 then the price on p3 when true will be displayed from cell R3,r4,r5,R6... Until another true signal appears.
imageFORMULA.png / V - Attached On 2022-10-26 08:45:27 UTC - Size: 4.61 KB - 136 views
[2022-10-26 09:04:15]
Sierra_Chart Engineering - Posts: 18843
This is not possible to do from a Spreadsheet:
I need help referencing an alert condition from a study on the main price chart.

You need to implement that alert condition formula within the Spreadsheet itself.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2022-10-26 12:40:15]
Sawtooth - Posts: 4186
I now need another formula to identify P3 and S3 signals when true and display that price (P3) on every consecutive cell until new signal becomes true...
Use another persistent variable formula.

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

Login

Login Page - Create Account