Hi,
Spending week-end working on using Exhaustive optimizer.
Have found this: https://wealth-lab.com/Discussion/Backtest-and-Optimization-Results-Don-39-t-Match-6718
Constructor > Backtestbegin > Initialize is the order of method calls I see.
Constructor - setting Paramters.
Backtestbegin - Parmeters are incrementing as expected (using AssignExplicitValues(double), Have tried Backtester.Cache["UserData"] as in the example
Initially used PreExecute like in the example but I am calculating all my buy sell signals for each set of parameters in Initialize.
Initialize - I am generating a TimeSeries of buy/sell signals and have tried storing them in Backtester.Cache["UserData"] as key, TimeSeries. Each time I do that the Cache increases to one entry.
In Execure I have tired:
When the code goes back to get the next set of parameters to process, the cache is reset to Count=0. I just don't seem to be able to keep the data for execute to work on.
Do you have any other examples of Exhaustive strategies, I have run public IndicatorRank() successfully.
I am lost so any help would be appreciated, also running out of time on the trial.
Thanks.
Spending week-end working on using Exhaustive optimizer.
Have found this: https://wealth-lab.com/Discussion/Backtest-and-Optimization-Results-Don-39-t-Match-6718
Constructor > Backtestbegin > Initialize is the order of method calls I see.
Constructor - setting Paramters.
Backtestbegin - Parmeters are incrementing as expected (using AssignExplicitValues(double), Have tried Backtester.Cache["UserData"] as in the example
Initially used PreExecute like in the example but I am calculating all my buy sell signals for each set of parameters in Initialize.
Initialize - I am generating a TimeSeries of buy/sell signals and have tried storing them in Backtester.Cache["UserData"] as key, TimeSeries. Each time I do that the Cache increases to one entry.
In Execure I have tired:
CODE:
(Dictionary<string, TimeSeries>) userData = (Dictionary<string, TimeSeries>)Backtester.Cache["UserData"]; TimeSeries listSignals = userData[key];
When the code goes back to get the next set of parameters to process, the cache is reset to Count=0. I just don't seem to be able to keep the data for execute to work on.
Do you have any other examples of Exhaustive strategies, I have run public IndicatorRank() successfully.
I am lost so any help would be appreciated, also running out of time on the trial.
Thanks.
Rename
The optimizer can run in parallel, so each run gets its own Backtester instance.
Your Response
Post
Edit Post
Login is required