sbuck143 88 posts msg #88967 - Ignore sbuck143 |
3/2/2010 3:53:24 PM
I am new to stockfetchers but am quite impressed with the functionality.
I am trying to create a simple filter based on the "4x2" concept.......the key tenets being:
1) The stock has experienced exactly 4 consecutive down days
2) followed by a sell signal when 2 up days are seen after #1 has occurred.
I found the default consecutive down day filter off the examples page (modified for 4 days):
but that returns all stocks where the close has been decreasing for 4 or more days. So it pulls out stocks with 5, 6, 8, 10+ down days! I want it to just be exactly 4 days, no more and no less.
Try as I might I can't find the magic combination of phrases to get it to do this.
Any help would be much appreciated.
|
Radiomuse 288 posts msg #88971 - Ignore Radiomuse |
3/2/2010 4:20:30 PM
You can just add a line like this...
close 5 days ago > open 5 days ago
|
sbuck143 88 posts msg #88972 - Ignore sbuck143 |
3/2/2010 4:39:30 PM
woohoo! The magic phrase found!
|
four 5,087 posts msg #88981 - Ignore four modified |
3/3/2010 12:30:59 AM
Comments:
0. Start with 1 white candle
1. The stock has experienced exactly 4 consecutive down days (4 red candles)
2. followed by a sell signal when 2 up days are seen after #1 has occurred. (2 white candles)
-------------------------------------------
Comments:
Do you see the difference between the two filters?
The second filter includes... the close of the red candle is below the previous red candle.
|
four 5,087 posts msg #88983 - Ignore four |
3/3/2010 1:19:01 AM
This filter provides...
4 red candles followed by 2 white candles
4 red candles with lower closes and 2 white candles with higher closes
|
Radiomuse 288 posts msg #88988 - Ignore Radiomuse |
3/3/2010 3:44:28 AM
Thanks for the coding tips Four!
|
sbuck143 88 posts msg #89035 - Ignore sbuck143 |
3/3/2010 10:59:46 PM
from four:
This filter provides...
4 red candles followed by 2 white candles
4 red candles with lower closes and 2 white candles with higher closes
*********************************************************************************************************
So if I wanted to backtest this filter, I'd have to separate the red candle part (the stuff up to the last two lines),
and then put the last two lines in the exit filter, right?
|
sbuck143 88 posts msg #89111 - Ignore sbuck143 modified |
3/4/2010 10:28:46 PM
okay i'm having a devil of a time trying to break the provided filters down into just a "4 down day" filter.
I would like to backtest this, and to the best of my knowledge the only way to do this would be to have a filter with only the 4 consecutive down days, and then in the backtest area, have the 2 Up candles as the exit criteria.
But my attempts to reverse engineer the formula are failing somewhere:
Help :(
+++++++++++++++++++++++++++++++++++++++++++++++++++++
Edit:
I think I got it:
show stocks where the close 4 days ago > open 4 days ago
and where the count(close is below close 1 days ago,4) equals 4
and where the count(close is below open,4) equals 4
used with the two up day higher close criteria (nice addition btw), and a 10% stop loss its generating a decent return in backtesting!
|
four 5,087 posts msg #89118 - Ignore four |
3/4/2010 11:32:18 PM
good luck and let us know the results
|
ns90212 6 posts msg #89178 - Ignore ns90212 |
3/5/2010 4:44:58 PM
|