How can I solve this problem? Is there any way to check if instrument was traded during the whole range I need before using Add(instrument)?
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Backtesting multiinstrument strategy wrong date range
Collapse
X
-
Backtesting multiinstrument strategy wrong date range
I'm backtesting multiinstrument strategy on a date range(for example 01.01.2011 - 12.01.2011). If there is a symbol in a list which is traded only part of that range (since 06.01.2011) all strategy executing only on the range of this instrument(since 06.01.2011).
How can I solve this problem? Is there any way to check if instrument was traded during the whole range I need before using Add(instrument)?Tags: None
-
I think I can use your code in OnBarUpdate(). And I need to use it in Initialize() before Add(). Should be smth like this:
How can I check it?protected override void Initialize()
{
if(EnoughData on Symbol)
{
Add(Symbol, PeriodType.Minute, 1);
}
}Last edited by nysetrader; 03-20-2012, 10:37 AM.
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by argusthome, 03-08-2026, 10:06 AM
|
0 responses
58 views
0 likes
|
Last Post
by argusthome
03-08-2026, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
39 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
19 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
21 views
0 likes
|
Last Post
|
||
|
Started by Mindset, 02-28-2026, 06:16 AM
|
0 responses
51 views
0 likes
|
Last Post
by Mindset
02-28-2026, 06:16 AM
|

Comment