edwkelly8
 ( 0.03% )
- ago
Provide a mechanism to determine when (time) SM's Status = LoadingData event is invoked so another thread or process (chart) could block until, for instance, the BacktestComplete() override is completed. If the data request was incomplete provide an error result.
0
518
Solved
6 Replies

Reply

Bookmark

Sort
Glitch8
 ( 10.94% )
- ago
#1
The Strategy execution process doesn’t even begin until the data loading is completed, so i don’t think this is feasible.
0
edwkelly8
 ( 0.03% )
- ago
#2
Could it be modified to begin after the data is requested?
0
Glitch8
 ( 10.94% )
- ago
#3
Not for WL8 that’s for sure. I was reading the other thread, is the driver here more being able to coordinate EXTERNAL data requests from within a strategy?
0
edwkelly8
 ( 0.03% )
- ago
#4
I'm not doing any external data requests now.

I think "driver" in my case is the streaming script which runs in SM on a dataset say for S&P 100, collects and wraps each bar with metadata, collect them to a List<> and then to "SetGlobal" . Say 8 seconds later the receiving script, from a chart of say SPY, does "GetGloball" and performs the statistical calculations and annotates each bar.
0
Glitch8
 ( 10.94% )
- ago
#5
OK I see. This is a pretty specific use-case. It sounds like the receiving strategy needs to "spin" in a loop checking GetGlobal for when the information is updated. Maybe the publishing script could also set a DateTime variable in SetGlobal, and the receiving strategy would look for the DateTime, and when it reaches the current threshold, it knows the information is updated and can continue. It doesn't sound like something we should consider as a general enhancement. Am I on the right track here?
0
edwkelly8
 ( 0.03% )
- ago
#6
Yes your response echo's exactly Cone's
QUOTE:
Just save the timestamp of the bar with the data. Then it's easy to see if it's up-to-date with the timestamp of the last bar of the primary script.
. Thanks
0
Best Answer

Reply

Bookmark

Sort