[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re:Code for Triangles



PureBytes Links

Trading Reference Links

In a message dated 9/30/98 7:00:10 AM Central Daylight Time,
support@xxxxxxxxxxxxxxxxxxx wrote:

> Here is EL code for detecting triangles. I wrote it today and used it to
>  scan 150 stocks which I track. The code could be improved a lot. But
>  here it is.
I can't remember who sent this indicator, maybe the CODE.  It gives a heads up
at times when you might be thinking of something else.


{Indicator calculates triangles based on SwingHighs and lows of a 10 day
range, and
with a swing strength of "1". Larger triangles can be calculated by increasing
the
strength and/or HighestBar/LowestBar range settings.}

Input:
OccurH1(1),OccurH2(2),OccurL1(1),OccurL2(2),PriceH1(High),PriceH2(High),PriceL
1(Low),
PriceL2(Low), StrenH(1),StrenL(1),Len(10);

IF
Triangle(OccurH1,OccurH2,OccurL1,OccurL2,PriceH1,PriceH2,PriceL1,PriceL2,
StrenH,StrenL,Len) = True THEN Plot1(10,"TriFinder")
Else Plot1(0,"TriFinder");

IF
Triangle(OccurH1,OccurH2,OccurL1,OccurL2,PriceH1,PriceH2,PriceL1,PriceL2,
StrenH,StrenL,Len) = True THEN Alert = True;