Parameter slider not controlling the default value
Author: zozzy
Creation Date: 5/8/2010 8:17 PM
profile picture

zozzy

#1
I wanted to optimize my simple script. So, I made a few changes to the code and it compliled OK. But I notice something strange when I change to default parameter in "Create Parameters". The Slider Window in the lower left hand corner seems to be controlling the default value, regardless of whether I change the default value in the editor and recompile or not.

For example I set the editor default values high and recomplile and run and the reults are based on the low values shown in the Slider Window...Not those shown on the complied editor. Obviously there is something I don't understand going on. I'd appreciate your help. Code attached. Thanks.

CODE:
Please log in to see this code.
profile picture

Eugene

#2
It happens because you have saved some parameter combination as default by clicking on "Save Parameters". The slider will be reset to this value when recompiling - vs. the default value in CreateParameter. To overwrite it, you can copy/paste the code in a blank strategy, or save a new Strategy parameter value combination as default.
profile picture

rgfekula

#3
It would be nice if the optomizer would list all the parameters that could be optomized and let you pick and choose. I am not a programmer but get the code from the rules as per below in the crossover/crossunder code from rules. Any examples I could refer to for fast and slow parameters

CODE:
Please log in to see this code.
profile picture

Eugene

#4
* Configure optimizable parameters in rule builder:

User Guide > Strategy Window > Strategy Builder > Parameter Sliders for the Strategy Builder.

* Adding optimizable parameters in code-based strategies:

WealthScript Guide > Programming Trading Strategies > Strategy Parameters.
profile picture

swuzy

#5
I agree w/ rqfekula's observation. It would be most convenient if optimizer would present check boxes next to list of parameters to optimize. I have 11 parameters on a code and monte carlo says it would take 276600 runs. But I would just like to tweak them one by one perhaps.

I thought "Save Parameter" would save it into the code, apparently not. Yet "Reset Parameter" does not appear to do anything to the parameter slider.

Of course "easy work around" is to slide the parameter back to the code default, and then hit "Save Parameter", but sometimes it is hard to fine tune it back to original.

Correction: Reset Parameter does work in a subseqent try to return them to code specs.

profile picture

Eugene

#6
Actually, it's been discussed many times and yes, WL5's optimizer should provide checkboxes like in legacy versions. Workarounds:

* Remove the parameter but don't apply changes to code.
* The way the rule builder works, it could easily produce duplicate parameters (see rgfekula's code above i.e. maFast, maFast_1) which are essentially the same thing. Optimize the code manually.

This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).