Setting Default Parameters in Rule-based strategy doesn't work
Author: grtrader
Creation Date: 9/2/2014 11:43 AM
profile picture

grtrader

#1
When I run the optimization for a Rules strategy, the results come up. I can right click on one of the runs and click on "Set these parameters as defaults for the strategy". I find the values actually change in the screen for the optimization strategy parameters; however, this is not reflected in the actual strategy parameters. The default values do not actually change when running the strategy again. Are they supposed to?
profile picture

Eugene

#2
As instructed by the Wealth-Lab User Guide > Reference > Data Panel > Strategy Parameters, have you activated preferred values by enabling the PV button in the lower right status bar of the Strategy Window?
profile picture

grtrader

#3
Yes. Are the Strategy Parameters in the lower left (under data sets) suppose to change to the new default values?
profile picture

Eugene

#4
Yes they do. Sorry, I overlooked that you're doing the different thing: I thought you were assigning PVs. Indeed, "Set these parameters as defaults for the strategy" does not take effect in Rule-based strategies. As a workaround, please "Open Code in new Strategy Window", optimize, and set the params as defaults.
profile picture

grtrader

#5
Please duplicate the following:
1. In Rule Based strategies set up a simple strategy: Buy at parabolic stop and sell at parabolic stop.
2. Set up all of the strategy parameters so they will be shown in the lower left window.
3. Run Strategy.
4. Open Code in new strategy window.
5. Run strategy.
6. Optimize and then right click on one of the runs and click on "Set these parameters as defaults for the strategy"
7. You will get errors and cannot compile. Some of the parameters in the code have been changed from "slider" to "strategy parameter" and some have not. Will not work unless I manually change the definitions.
profile picture

Eugene

#6
Yes, we're already aware of this issue. (Just updated the Open Issues list.) It's caused by an inability to handle parameters with identic names under certain conditions. You can encounter this, for example, when adding two rules from the same group e.g. a moving average crossover or Parabolic stop. This is why our recommendation to the users has always been to enforce unique strategy parameter names (which is not as easy/natural to do as in code-based strategies).

Workaround: in the Rule Wizard, click on the duplicating parameter name (there are 3: "Accel Up, Down and Max") and rename it so that it becomes unique across all existing conditions e.g. "Accel Up 1" and "Accel Up 2" etc etc.
profile picture

grtrader

#7
OK - I have changed the names and it compiles fine. However, after optimizing and then right clicking on one of the runs and clicking on "Set these parameters as defaults for the strategy", the new default values are not used on the chart (or reflected in the Strategy Parameter window in the lower left), even though they have been changed in the code. Are they not supposed to?
profile picture

Eugene

#8
1. Reopen the Strategy, OR
2. Click "Compile", drag to change any parameter slider, then click "Reset".
profile picture

grtrader

#9
That works. Thanks.
profile picture

LenMoz

#10
RE: Post #2
QUOTE:
As instructed by the Wealth-Lab User Guide > Reference > Data Panel > Strategy Parameters, have you activated preferred values by enabling the PV button in the lower right status bar of the Strategy Window?

I couldn't find a "PV" button on my Strategy Window until I first right clicked the "Strategy Parameters" window and stored the values. Then a "PV" button magically appeared! This behavior is documented in the User Guide.
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).