Second question, assuming the above works and it is does test all contracts in the test period, if I have code in my script that tests for which contract expiry it is trading on, will the script see FESX 03-14 (as that is the contract selected in the strategy analyzer) OR the actual contract expiry it is testing?
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Merge Non Back adjusted
Collapse
X
-
Merge Non Back adjusted
If I am using the Strategy analyzer for WFA on say FESX (set to Merge Non Back Adjusted) from March 2010 to March 2012, and I select FESX 03-14 from the contract list on the left of the strategy analyzer. Will the analyzer then test all the FESX contract that fall within the test period or will it not test at all as FESX 03-14 has no data for that period?
Second question, assuming the above works and it is does test all contracts in the test period, if I have code in my script that tests for which contract expiry it is trading on, will the script see FESX 03-14 (as that is the contract selected in the strategy analyzer) OR the actual contract expiry it is testing?Tags: None
-
Thanks, bur how about the logic test in the strategy,
// Prevent System from trading before coontract is front month.
if(
((Instrument.Expiry.Month == 3) && (Time[0].Date.Month == 12) && (Time[0].Date.Day < iStartTradeDate))
|| ((Instrument.Expiry.Month == 3) && ((Time[0].Date.Month >3) || (Time[0].Date.Month <12)))
|| ((Instrument.Expiry.Month == 6) && (Time[0].Date.Month == 3) && (Time[0].Date.Day < iStartTradeDate))
|| ((Instrument.Expiry.Month == 6) && ((Time[0].Date.Month >6) || (Time[0].Date.Month <3)))
|| ((Instrument.Expiry.Month == 9) && (Time[0].Date.Month == 6) && (Time[0].Date.Day < iStartTradeDate))
|| ((Instrument.Expiry.Month == 9) && ((Time[0].Date.Month >9) || (Time[0].Date.Month <6)))
|| ((Instrument.Expiry.Month == 12) && (Time[0].Date.Month == 9) && (Time[0].Date.Day < iStartTradeDate))
|| ((Instrument.Expiry.Month == 12) && ((Time[0].Date.Month >12) || (Time[0].Date.Month <9)))
)
{
return;
}
Will the strategy see the actual contract it is testing on or FESX 03-14?
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by argusthome, 03-08-2026, 10:06 AM
|
0 responses
77 views
0 likes
|
Last Post
by argusthome
03-08-2026, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
45 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
27 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
32 views
0 likes
|
Last Post
|
||
|
Started by Mindset, 02-28-2026, 06:16 AM
|
0 responses
62 views
0 likes
|
Last Post
by Mindset
02-28-2026, 06:16 AM
|

Comment