Optimizing

Posted By: MatPed

Optimizing - 03/04/15 17:08

Hi, just started with Zorro and it looks promising...
In a testing strategy I have declared the following parameters:

var slATR = optimize(2,1,3,0.1);
int tpMtp = optimize (3,2,5);
var ratioATR = optimize(2.0,1.5,7.0,0.1);
int adxFilter = optimize (9,5,30,1);

After the optimization process I receive the following optimized values:

EUR/USD:VB 1.198 4.30 5.91 7.00=> 3.774

The first and third parameter should be a multiple of 0.1 , but they are not. What am I missing?

Even the fourth parameter has an issue because it should be an integer while is represented as a decimal. But I understand that this could be just the preferred format to store the parameters in the .par file and the appropriate conversion is done when loaded.

Thank you in advance
Posted By: jcl

Re: Optimizing - 03/05/15 17:22

The optimize results are not a multiple of the step width. They can have any value, even between steps.
Posted By: MatPed

Re: Optimizing - 03/05/15 17:50

Ok, gotcha. I had misunderstood what stated in the manual. Thx
Posted By: Sphin

Re: Optimizing - 01/24/16 16:46

The manual states at a lot of indicators "int TimePeriod", so I wonder if Zorro really uses decimales in lengths of time periods according to the results of optimizing and the content of .par files? Is a moving average of 5.34 time periods defined anyway?
Posted By: jcl

Re: Optimizing - 01/25/16 10:11

It is theoretically possible to define a MA with a non-integer time period, but all Zorro indicators use integer time periods.
Posted By: Sphin

Re: Optimizing - 01/25/16 20:51

Okay, the optimize function writes the following .par file:

AUD/JPY 10.8 50.2 120=> 8.705
AUD/USD 8.11 70.7 140=> 2.156
EUR/AUD 9.81 70.1 270=> 1.770

where the first and second parameter are time periods of SMAs. I guess they are rounded to int when used in test & trade according to your answer? 10.8 to 11, 8.11 to 8?
Posted By: jcl

Re: Optimizing - 01/26/16 14:46

No, they are truncated, not rounded. For rounding you must explicitely use the round() function.
Posted By: Sphin

Re: Optimizing - 01/26/16 17:25

SMA = series(SMA(Price, round(optimize(10,10,200),1)));

This way for rounding to the nearest integer?
Posted By: jcl

Re: Optimizing - 01/27/16 09:56

Yes.
© 2024 lite-C Forums