Login Page - Create Account

Support Board


Date/Time: Mon, 16 Sep 2024 20:05:25 +0000



Post From: A way to Apply the Crossover Alert to Moving Average Bands.

[2015-06-19 05:43:37]
Sawtooth - Posts: 4091
Try this:

Add two instances of the Color Bar Based On Alert Condition study.

Put this formula in one:
=AND(MIN(ID1.SG1,ID1.SG2)>MAX(ID2.SG1,ID2.SG2),MIN(ID1.SG1[-1],ID1.SG2[-1])<MAX(ID2.SG1[-1],ID2.SG2[-1]))
and this formula in the other:
=AND(MAX(ID1.SG1,ID1.SG2)<MIN(ID2.SG1,ID2.SG2),MAX(ID1.SG1[-1],ID1.SG2[-1])>MIN(ID2.SG1[-1],ID2.SG2[-1]))

where ID1 is the faster band, and ID2 is the slower band.

-This will give you a visual of where the alerts will be.
-If you don't want the visual, you could put each formula in the two different band studies.
-You could combine the two formulas with =OR(....) and put it in any study's Alerts tab.