A simple algorithm for trading

I newly learnt an algorithm which has a 3 step process to screen the stocks. Was wondering how these three steps could be written in Streak screener. The 3 steps are as follows

ENTER When

  1. Rising SMA 50
  2. Crossing the lower Bollinger Curve
  3. Has a big green candle touching the intersection of rising SMA50 and Lower Bollinger curve

EXIT When

  1. Falling SMA50
  2. Crossing the upper Bollinger curve
  3. Has a big red candle touching the intersection of falling SMA50 and Ubber Bollinger curve

Can someone help how this could be configured algorithmically in Streak scanner/Strategy

This can be created but need more data to understand point 3. Please elaborate

1 Like

Thanks Krishnendu

What the point 3 means is that there needs to be a hammer kind of Bullish green Candle in close proximity of the intersection of rising SMA50 and Lower bollinger curve (in case of entry signal). In case of exit signal, this translates to a close proxity of a Bearish red candle near the intersection of falling sma50 and upper bollinger curve.

This can be done at different time intervals to look for signals for intraday positions or for a short to long term position.

You can create 1 & 2 but number 3 is a discretionary type rule because there is subjectivity involved. You can create a rule for LBB and SMA50 crossover along with a Green candle on the same candle itself but close proximity is subjective.

Here are the condition for number 1 & 2

  1. Period Min (15, SMA(Close,50,0) - SMA(Close,50,-1) ) higher than 0

  2. SMA(Close,50,0) crosses above LBB(close, 20,2,simple,0)

To create a rule for LBB and SMA50 crossover along with a Green hammer on the same candle, you can write

Period Min (15, SMA(Close,50,0) - SMA(Close,50,-1) ) higher than 0 and
SMA(Close,50,0) crosses above LBB(close, 20,2,simple,0) and
Close(0) higher than Open(0) and ( Open(0) - Low(0) ) higher than Abs( Close(0) - Open(0) ) * 3 and ( High(0) - Close(0) ) lower than Abs( Close(0) - Open(0) )

1 Like