Hi,

I'm looking for your opinions/thoughts regarding a strategy that I've been coding. Actually, it's the WFO results that I have questions about.

The code:

Code:
function run()
{
Hedge = 2;
set(PARAMETERS);



NumWFOCycles = 5;

BarPeriod = 60;
StartDate = 20020101;
EndDate = 20130101;


var TimeCycle = optimize(1000,500,1500,50,0);
var TimeFactor = optimize (2, 1, 3, 0.2, 0);

vars Pris = series(priceClose());
vars LP1 = series(LowPass(Pris, TimeCycle));
vars LP2 = series(LowPass(Pris, TimeFactor*TimeCycle));
vars Signal = series(0);

Stop = optimize(2,1,3,0.1,0) *ATR(50);
Trail = optimize(100,75,125,5,0) *PIP;

var NumSignal = 60;

if (NumOpenLong == 0 && LP1[0] > LP2[0] && (rising(LP1)))
{
   if(Sum(Signal+1,NumSignal) == 0)
		if(enterLong())
			Signal[0] = 1;
	
	

}
	 
else if (NumOpenShort == 0 && LP1[0] < LP2[0] && (falling(LP1)))
{
   if(Sum(Signal+1,NumSignal) == 0)
		if(enterShort())
			Signal[0] = 1;
	
	

}
	
	



	
plot  ("LP1", LP1[0], 0, BLUE);
plot  ("LP2", LP2[0], 0, RED);
PlotWidth = 600;
PlotHeight1 = 300;
}



I deeply appreciate any comments/improvements of my coding.

Regarding the WFO:

If I use the code above, I get the following results:

http://sv.tinypic.com/view.php?pic=2untsp3&s=8#.UvEpwvl5NVU

Which looks kinda neat... But I've tested it with other settings. For example, I did change the EndDate to 20140101 instead of 20130101. And the results of this was quite amazing(or not so amazing):

http://sv.tinypic.com/view.php?pic=i2t05g&s=8#.UvEqSfl5NVU

So, can anyone enlight me how come the difference is that palpable?

Also, the result varies kinda much when I use more WFO cycles, for example.

Last, I've checked in the manual but I don't really understand what the error factor(right next to Ulker index) is telling me, so if someone could tell me, that would be kind.

Thank you!