NinjaTrader Support Forum  
X

Attention!

This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com


Go Back   NinjaTrader Support Forum > Application Technical Support > Automated Trading

Automated Trading Support for automated trading systems using NinjaScript. Support for our ATI (Automated Trading Interface) used to link an external application such as TradeStation and eSignal to NinjaTrader.

Reply
 
Thread Tools Display Modes
Old 11-09-2006, 11:09 AM   #1
tmd
Member
 
Join Date: Apr 2006
Location: , ,
Posts: 38
Thanks: 0
Thanked 0 times in 0 posts
Post imported post

I've used symbol mapping to tradethe e-miniS&P using the big S&P charted in TS. How do I map the S&P index, $SPX.X, to trade the e-mini S&P? I tried the following but it does not work:

Symbol map - External.......$SPX.X

Please let me know if you have any suggestions. Thanks.
tmd is offline  
Reply With Quote
Old 11-09-2006, 08:16 PM   #2
NinjaTrader_Dierk
Administrator
 
NinjaTrader_Dierk's Avatar
 
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
Post imported post

Not sure I follow:
- you need to map the TS instrument "$SPX.X" to NT "ES". I guess you have done that already for the TS "Big S&P" -> mapping should not be the issue
- prices/prices ranges and tick sizes potentially are different (have not checked). This could affect price calculations for limit/stop orders.
NinjaTrader_Dierk is offline  
Reply With Quote
Old 12-04-2006, 05:45 AM   #3
tmd
Member
 
Join Date: Apr 2006
Location: , ,
Posts: 38
Thanks: 0
Thanked 0 times in 0 posts
Post imported post

I've rephrased my question. Can you provide an example of how to accomplish symbol mapping from an index to a future contract?
tmd is offline  
Reply With Quote
Old 12-04-2006, 05:59 AM   #4
NinjaTrader_Dierk
Administrator
 
NinjaTrader_Dierk's Avatar
 
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
Post imported post

Rethinking that issue: How about not going through the mapping logic (which could fail for futures due to NT internal expiry handling), but submitting the order on the correct NT instrument in TS right away?

The idea would be to copy/clone e.g. the TS functions NTBuyMarket and NTCommand (called by NTBuyMarket) and put in the actual symbol name, like

(see TS function NTCommand)
NTCommand = Command(Cmd, Account, "ES 12-06", Action, Quantity, OrderType, LimitPrice, StopPrice, TimeInForce, Oco, OrderId, Template, Strategy);
NinjaTrader_Dierk is offline  
Reply With Quote
Old 12-04-2006, 06:25 AM   #5
tmd
Member
 
Join Date: Apr 2006
Location: , ,
Posts: 38
Thanks: 0
Thanked 0 times in 0 posts
Post imported post

Maybe I'm missing something, but I cannot find either functions, NTBuyMarket/NTCommand, in TS. By the way, I have the latest TS build 3258.
tmd is offline  
Reply With Quote
Old 12-04-2006, 06:31 AM   #6
NinjaTrader_Dierk
Administrator
 
NinjaTrader_Dierk's Avatar
 
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
Post imported post

These are TS functions provided by NT which you need to import into TS after installing NT (they are not there by default). Please consult the docs for how to import those functions.
NinjaTrader_Dierk is offline  
Reply With Quote
Old 12-04-2006, 07:11 AM   #7
tmd
Member
 
Join Date: Apr 2006
Location: , ,
Posts: 38
Thanks: 0
Thanked 0 times in 0 posts
Post imported post

I've imported the functions but I'm confused as to how to implement your suggestion. Are you saying I should use the NTCommand in my strategy? And if so, should Iwrite it exactly as you suggested by putting "ES 12-06" in the NTCommand line?
tmd is offline  
Reply With Quote
Old 12-04-2006, 07:16 AM   #8
NinjaTrader_Dierk
Administrator
 
NinjaTrader_Dierk's Avatar
 
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
Post imported post

No, you need to call the "Command" DLL function directly. I provided the NTBuyLimit and NTCommand wrappers of this DLL function to give you an idea on how this all works.

The "Command" DLL function call then holds the NT instrument name e.g. "ES 12-06".

Please let me know if you need further assistance. I then will try to get you in touch with someone who provides NT consulting services.
NinjaTrader_Dierk is offline  
Reply With Quote
Old 12-07-2006, 09:41 AM   #9
tmd
Member
 
Join Date: Apr 2006
Location: , ,
Posts: 38
Thanks: 0
Thanked 0 times in 0 posts
Post imported post

I guess I'll need some help. Please let me know who to contact. Thanks.
tmd is offline  
Reply With Quote
Old 12-07-2006, 09:53 AM   #10
NinjaTrader_Ray
Administrator
 
NinjaTrader_Ray's Avatar
 
Join Date: Nov 2004
Location: Denver, CO, USA
Posts: 11,163
Thanks: 6
Thanked 45 times in 32 posts
Post imported post

http://fin-alg.com/index.html
NinjaTrader_Ray is offline  
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -6. The time now is 09:23 AM.