Author: handlep
This screener will find candlesticks with a real body of one third or less the size of the overall candle, following an advance. Therefore it will detect Hangmen, Hammers, inverted Hammers, Spinning Tops, Dojis, etc.
I have used ProRealTime’s Bearish Engulfing code to detect the advance.
Note: Rather than write several screeners to detect the individual candle types, this screener is relatively generic, so will throw up candles which do not necessarily imply a reversal – for example, the main body may not be close enough to the end of the candle to be a true hammer or hanman, and not close enough to the centre to be a spinning top. Obviously any such detections should be discarded.
Good luck in your trading.
REM Compute the power of the bullish trend
// Find the lowest quote on the last 8 bars
LowPoint = LOWEST[8](LOW)
// Compute the variation of price from this point to now
Advance = CLOSE- LowPoint
// Compute the usual volatility of the stock (median of True Range)
Norm = SUMMATION[3](TR) - HIGHEST[3](TR) - LOWEST[3](TR)
REM Stock picking : only candles whose real body is equal to, or less than, one third of the overall range.
Filter = ABS(open - close) <= (ABS(high-low))/3
REM We keep the most serious advances
SCREENER [ Filter ] (Advance / Norm AS"Trend Power")