Login Page - Create Account

Support Board


Date/Time: Sun, 29 Mar 2020 21:06:21 +0000



How to generate an alert when a study reverses direction?

[2018-10-14 16:42:35]
User360283 - Posts: 311 | Ending Date: 2020-03-31
Study is Double Exponential with Auto-Coloring Based on +/-
I want to generate and alert when the study bottoms out and then reverses upward.
Please see encl. png yellow circle. Thanks
imagesierra5.PNG / V - Attached On 2018-10-14 16:41:59 UTC - Size: 142.1 KB - 255 views
[2018-10-14 17:23:37]
Xfanman1 - Posts: 320 | Ending Date: 2020-01-31 [Expired]
Compare the current direction against the bar or two before. If you use [-1] to reference prior bars you can capture the change in the current bar. Just an example if your Study is ID10.SG1 you could try:

=AND(ID10.SG1>ID10.SG1[-1],ID10.SG1[-1]<ID10.SG1[-2])

This states that the current bar is above the previous bar AND the previous bar is less than the bar prior to that. This should capture the turn. You can add additional bar lookbacks if you want to make sure it wasn’t just a 1 bar change. You can also specify if you are only looking for this directional change above or below a certain level by adding something like ID10.SG1 < 20 if you only want to alert when the change happens below 20 (or whatever value you consider the bottom to be of your study)


Scott
Date Time Of Last Edit: 2018-10-14 17:27:08
[2018-10-14 22:54:35]
User360283 - Posts: 311 | Ending Date: 2020-03-31
thanks for the reply.
I've tried your approach without getting my desired results.
I'm thinking that the way to do it is to calculate the distance from the high and low and determine if the difference after the zero line is increasing or decreasing.
So far, this is a bit beyond my abilities to code.
Maybe Sierra can come up with a study that calculates the area between two curves and reports if it is increasing or decreasing.
[2018-10-14 23:53:54]
Xfanman1 - Posts: 320 | Ending Date: 2020-01-31 [Expired]
There is a study which measures the distance between 2 studies.

https://www.sierrachart.com/index.php?page=doc/StudiesReference.php&ID=185&Name=Study_Subgraphs_Subtract_-_Difference

It would be simple enough to write your alert to watch for increasing or decreasing measurements if that's of any help for your alert.

--
Scott
[2018-10-15 15:20:44]
User360283 - Posts: 311 | Ending Date: 2020-03-31
Scott - thanks for your help. I'm a better trader and not much of a programmer. LOL.
[2018-10-15 15:22:36]
User360283 - Posts: 311 | Ending Date: 2020-03-31
I've got some indicator ideas that need programming. Fine to make them contributed studys. Interested?
[2018-10-15 16:18:47]
Xfanman1 - Posts: 320 | Ending Date: 2020-01-31 [Expired]
I've got some indicator ideas that need programming. Fine to make them contributed studys. Interested?

If that's directed to me, I'm no programmer either. I taught myself just enough to be dangerous ;^) There ARE some talented programmers on here though that might be able to help you out. I'd start with the list that SC maintains of the service providers if you'd really like to get something coded.

Best of luck....Scott
[2018-10-15 17:04:54]
John - SC Support - Posts: 1660 | Ending Date: 2020-04-29
Here is the link to developers of Custom Studies for Sierra Chart: https://www.sierrachart.com/index.php?page=doc/SierraChartStudyAndSystemProgrammers.php#ThirdPartyList
[2019-05-04 16:23:11]
Ackin - Posts: 666 | Ending Date: 2020-09-04
Hi,
Study "Dema reverse"

It's possible download it for free from our CZ/SK forum.



More information:
https://www.sierrachart.com/SupportBoard.php?PostID=178661#P178661
imagedema reverse.png / V - Attached On 2019-05-04 16:22:51 UTC - Size: 22.29 KB - 78 views

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

Login

Login Page - Create Account