Page 1 of 1

Mean Reversion System

Posted: Sat May 21, 2016 7:09 pm
by kindeb01
Hi,

I hope someone can help me with emulating this strategy "Mean Reversion System" from Dr Thomas Carr in his book "Market Neutral Trading" using Edgerater templates. The strategy is sold as an add-on in Metastock. He said it is also somewhat codeable in StockCharts and is quite profitable.

The strategy scans for a long-short pair to trade at the beginning of every month. The idea behind the scan is that a stock that has travelled too far out of its BB range will soon revert back to its mean . For Long we scan for following characteristics:

-stock has good fundamentals such as good earning growth, low debt to equity ratio and institutional and/or insider buying
-stock has traded outside of lower Bollinger Band over several days (not gap outside lower band on bad news)
-trading significantly under mean "the 20 SMA"

For short we simply reverse the requirements.

I think this strategy can be emulated using EdgeRater but just not sure how. I believe the date to scan using strategy is probably also important. It may not need to be beginning of month when scan is carried out. Any existing long-short pair that doesn't come up in new scan is then closed out.

Please advise how this strategy can be simulated using EdgeRater.


Thank you.


Kin

Re: Mean Reversion System

Posted: Sun May 22, 2016 7:15 am
by henry1224
He talks about the 50 and 200 day moving averages and the Bollinger bands set to those lengths.

https://www.marketfy.com/content/74202- ... ion-setups

here is the basic code

MID:= MA(CLOSE,50);
UPPER:= MID + 2*STDP(CLOSE,50);
LOWER:= MID - 2*STDP(CLOSE,50);
ShortEvent: Cross(C,Upper),ColorRed;
LongEvent: Cross(Lower,C),ColorGreen;
Short2Event: Sum(C>Upper,2)>1,ColorDarkRed;
Long2Event: Sum(C<Lower,2)>1,ColorLime;

Re: Mean Reversion System

Posted: Sun May 22, 2016 1:46 pm
by henry1224
here is a chart w 50 and 20 Bollinger bands w 2 std,
Also has rainbow osc and rainbow Ma's

Image

Re: Mean Reversion System

Posted: Sun Jun 05, 2016 1:55 am
by kindeb01
Thank you, Henry. Will give it a go.


Kin