Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Optimization - keep best # results per data series
Collapse
X
-
Optimization - keep best # results per data series
When running an optimization that includes optimizing on data series, is there a way to only keep the best # of results **per data series**, instead of the best # total? I want to see the top 5 results from each data series for example.Last edited by andrewnavratil; 03-23-2024, 06:00 AM.Tags: None
-
Ok understood, thanks.
Do you know if there's anything at the api level to hook into those results?
I discovered there are api hooks into the optimization process and performance metrics - such as OnOptimize(), Strategies[0].OptimizationParameters. I didn't see a method directly related to the results or best results however. Maybe I'm missing something in the docs.
For a somewhat related example, I am utilizing SetState(State.Terminated) in the State.DataLoaded method to get a custom set of data values for the optimization results that don't fit nicely into integer increments (so it only executes iterations on values of 5;21;1 and then 25;125;5 for example, all grouped in one results list). Hooking in like that to limit the number of results per data series would work too.
Comment
-
Hello zagier,
You can access the system performance collection in the optimizer type by using Results, you can see the genetic optimizers code for an idea of how to use that.
I couldn't comment on the SetState example you provided, you could certainly try that but I am unsure if that would let you limit the results per data series. If you wanted to isolate the data for a specific series all I could suggest would be to run a optimization and do not select optimize data series.
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by CaptainJack, 05-29-2026, 05:09 AM
|
0 responses
160 views
0 likes
|
Last Post
by CaptainJack
05-29-2026, 05:09 AM
|
||
|
Started by CaptainJack, 05-29-2026, 12:02 AM
|
0 responses
81 views
0 likes
|
Last Post
by CaptainJack
05-29-2026, 12:02 AM
|
||
|
Started by charlesugo_1, 05-26-2026, 05:03 PM
|
0 responses
125 views
0 likes
|
Last Post
by charlesugo_1
05-26-2026, 05:03 PM
|
||
|
Started by DannyP96, 05-18-2026, 02:38 PM
|
1 response
206 views
0 likes
|
Last Post
|
||
|
Started by CarlTrading, 05-11-2026, 05:56 AM
|
0 responses
184 views
0 likes
|
Last Post
by CarlTrading
05-11-2026, 05:56 AM
|

Comment