I am using a signal which acts as a TradeManager to control position sizing, profit targets, trading times and limits, broker sync, etc, while passing trading instructions (i.e., trend direction, position sizes….) to various independent signals via the save_global_data function.
The TradeManager utilizes 10000 contract bars configured as data2 to calculate the various components (i.e., trend, OB/OS levels) on a higher time frame. The calculations are then used to pass trading instructions to the various signals which are utilizing 1000 contract bars in data1.
I originally used the ADE and TypeZero functions which seem to have problems with contract / volume bars. I read a post about the save_global_data function and decided to give it a test. Thereafter, the TradeManager and the various signals perform well and as expected.
The only problem I’ve experienced is when I tried to optimize a signal. It kicks up a EL Collections Error with the Source string: “MapSC.SortRows: All of the lists in the map must be the same size.” See attached Error 1 image.
I next tried to use a single data stream (data1) on fifteen minute bars for both the TradeManager and a single independent signal, and again received an EL Collections error, this time with the source string: “there is no collection with that ID.” See Error 2 image
Any idea on how to correct this, or is it not possible to optimize a signal when using the save_global_data function?
Optimizing Problem when using Save_Global_Data function [SOLVED]
Optimizing Problem when using Save_Global_Data function
- Attachments
-
- EL Collections Error 2 (15 Min).png
- (4.4 KiB) Downloaded 1015 times
-
- EL Collections Error 1 ((10000).png
- (4.62 KiB) Downloaded 1030 times
- Henry MultiСharts
- Posts: 9165
- Joined: 25 Aug 2011
- Has thanked: 1264 times
- Been thanked: 2958 times
Re: Optimizing Problem when using Save_Global_Data function [SOLVED]
Hello Jdog,
Please try disabling multi core CPU support for optimization.
Download and unzip the attachment. Close MultiCharts and all its products.
Make sure that all MC processes are ended.
Then double click on the unzipped file One_Thread_ForOptimize.reg
Click Yes to import the registry key.
Please try disabling multi core CPU support for optimization.
Download and unzip the attachment. Close MultiCharts and all its products.
Make sure that all MC processes are ended.
Then double click on the unzipped file One_Thread_ForOptimize.reg
Click Yes to import the registry key.
- Attachments
-
- All_Thread_ForOptimize.zip
- (523 Bytes) Downloaded 731 times
Re: Optimizing Problem when using Save_Global_Data function
Thanks, Henry. That seems to have stopped the error messages.
There does seem to be a huge difference now in the time required to optimize even a single input.
Is this the consequences of using a single thread as opposed to all threads for the optimization?
There does seem to be a huge difference now in the time required to optimize even a single input.
Is this the consequences of using a single thread as opposed to all threads for the optimization?
- Henry MultiСharts
- Posts: 9165
- Joined: 25 Aug 2011
- Has thanked: 1264 times
- Been thanked: 2958 times
Re: Optimizing Problem when using Save_Global_Data function
That is correct. When all CPU cores are utilized - the optimization speed is increased as the calculations are divided into multiple flows.Is this the consequences of using a single thread as opposed to all threads for the optimization?
Re: Optimizing Problem when using Save_Global_Data function
I was afraid of that. I will have to explore alternative methods for passing information from one signal to another that can be optimized a little more efficiently.
Thanks, nonetheless.
Thanks, nonetheless.