NexusFi: Find Your Edge


Home Menu

 





NT 8 Autotrading strategy issues


Discussion in NinjaTrader

Updated
      Top Posters
    1. looks_one TheGaryGuy with 3 posts (0 thanks)
    2. looks_two JonnyBoy with 2 posts (2 thanks)
    3. looks_3 UweH with 1 posts (1 thanks)
    4. looks_4 ganntrader312 with 1 posts (0 thanks)
    1. trending_up 1,888 views
    2. thumb_up 3 thanks given
    3. group 5 followers
    1. forum 5 posts
    2. attach_file 0 attachments




 
Search this Thread

NT 8 Autotrading strategy issues

  #1 (permalink)
 TheGaryGuy 
Bellevue, WA/USA
 
Experience: Advanced
Platform: NinjaTrader, TOS, TDAmeri
Broker: ThinkOrSwim, TastyWorks.com, TDAmeritrade, Interactive Brokers (soon)
Trading: Index and Stock options, Stocks (seldom), Nadex (just starting), Forex
Posts: 33 since Oct 2012
Thanks Given: 47
Thanks Received: 26

I am looking to automate (sim and real) trades on NT 8. I know others have done this also. I have a couple questions. 1. How to minimize risk when the connection from my machine to NinjaTrader brokerage is lost? (computer down, network down, power outage). 2. How to minimize slippage with both entry and exit orders? 3. How to handle (in code?) partial fills.

Started this thread Reply With Quote

Can you help answer these questions
from other members on NexusFi?
About a successful futures trader who didn´t know anyth …
Psychology and Money Management
Better Renko Gaps
The Elite Circle
Cheap historycal L1 data for stocks
Stocks and ETFs
Quant vue
Trading Reviews and Vendors
What broker to use for trading palladium futures
Commodities
 
  #2 (permalink)
 
JonnyBoy's Avatar
 JonnyBoy 
Montreal, Quebec
 
Experience: Advanced
Platform: NinjaTrader 8
Broker: Kinetick
Trading: ES
Posts: 1,561 since Apr 2012
Thanks Given: 706
Thanks Received: 3,858


TheGaryGuy View Post
I am looking to automate (sim and real) trades on NT 8. I know others have done this also. I have a couple questions. 1. How to minimize risk when the connection from my machine to NinjaTrader brokerage is lost? (computer down, network down, power outage). 2. How to minimize slippage with both entry and exit orders? 3. How to handle (in code?) partial fills.

1. NinjaTrader has some built in options for how you want to it to handle your strategy on connection loss. Tools > Options > Strategies. LMT orders will be sitting at the exchange, so you will covered if you lose connection. MIT orders and MKT orders will be resting on your machine.

2. Use LMT orders and you won't see any slippage. However, this might not always be practical for an automated entry. For example, price might have moved away from your limit order by the time the automated strategy places it. I would use MKT orders for your entry (guaranteed a fill with no partial fills although not guaranteed at the same price) and LMT orders for your exits.

3. Assuming you are entering your strategy at MKT I guess you are talking about a stack of LMT orders sitting at the same target price and the market doesn't trade through that price and only partially takes out your LMT order stack? This has never been an issue for me personally. In the rare event that only one of my LMT orders gets taken out but another doesn't, my strategy still knows the trade is live and won't do anything until it is flat, one way or another.

--------------------------------------------------------
- Trade what you see. Invest in what you believe -
--------------------------------------------------------
Reply With Quote
Thanked by:
  #3 (permalink)
 TheGaryGuy 
Bellevue, WA/USA
 
Experience: Advanced
Platform: NinjaTrader, TOS, TDAmeri
Broker: ThinkOrSwim, TastyWorks.com, TDAmeritrade, Interactive Brokers (soon)
Trading: Index and Stock options, Stocks (seldom), Nadex (just starting), Forex
Posts: 33 since Oct 2012
Thanks Given: 47
Thanks Received: 26



JonnyBoy View Post
1. NinjaTrader has some built in options for how you want to it to handle your strategy on connection loss. Tools > Options > Strategies. LMT orders will be sitting at the exchange, so you will covered if you lose connection. MIT orders and MKT orders will be resting on your machine.

2. Use LMT orders and you won't see any slippage. However, this might not always be practical for an automated entry. For example, price might have moved away from your limit order by the time the automated strategy places it. I would use MKT orders for your entry (guaranteed a fill with no partial fills although not guaranteed at the same price) and LMT orders for your exits.

3. Assuming you are entering your strategy at MKT I guess you are talking about a stack of LMT orders sitting at the same target price and the market doesn't trade through that price and only partially takes out your LMT order stack? This has never been an issue for me personally. In the rare event that only one of my LMT orders gets taken out but another doesn't, my strategy still knows the trade is live and won't do anything until it is flat, one way or another.

Thanks JonnyBoy for your ideas. My backtested strategy uses market orders to enter on a signal and market orders to exit on a trend following end of candle trailing stop (not a standard trail). So there will be slippage on the entries and exits based on the market orders. I can switch the entries to a stop limit order (puts in a limit order when the price is touched) but I will have to add/subtract a tick or two to get more fills. I can't do that on the exits as when I want out, I want out now.

While I have sim backtesting experience I do not have any experience with a real account doing an automated strategy and don't have a clue about the real time differences.

My biggest worry is with market orders not living on the exchange and being managed by my local computer. Any outage would leave me with an unmanaged open futures contract (no stop or target). This kind of risk is not part of anyone's business plan.

Have you ever used a bogus emergency stop loss order far from the market for a catastrophic stop loss in case of out age? (at end of each trade this stop/target would be removed).

Started this thread Reply With Quote
  #4 (permalink)
 
JonnyBoy's Avatar
 JonnyBoy 
Montreal, Quebec
 
Experience: Advanced
Platform: NinjaTrader 8
Broker: Kinetick
Trading: ES
Posts: 1,561 since Apr 2012
Thanks Given: 706
Thanks Received: 3,858


TheGaryGuy View Post
Thanks JonnyBoy for your ideas. My backtested strategy uses market orders to enter on a signal and market orders to exit on a trend following end of candle trailing stop (not a standard trail). So there will be slippage on the entries and exits based on the market orders. I can switch the entries to a stop limit order (puts in a limit order when the price is touched) but I will have to add/subtract a tick or two to get more fills. I can't do that on the exits as when I want out, I want out now.

While I have sim backtesting experience I do not have any experience with a real account doing an automated strategy and don't have a clue about the real time differences.

My biggest worry is with market orders not living on the exchange and being managed by my local computer. Any outage would leave me with an unmanaged open futures contract (no stop or target). This kind of risk is not part of anyone's business plan.

Have you ever used a bogus emergency stop loss order far from the market for a catastrophic stop loss in case of out age? (at end of each trade this stop/target would be removed).

The benefits of a UPS cannot be understated, but you will need to power your incoming router from the same UPS power source or that will shut down too if overall power failure occurs to your property. To be honest, in over a decade I can count on one hand the number of times this has happened. And for half of those I wasn't even in a position. So, in all honestly I wouldn't worry about it too much.

At the end of the day your brokers number should be on speed dial. I have used my broker once in a decade to get me out of a position. If you live in a very spotty area for power then maybe you need to be more cautious, but as long as you have a plan of what to do if it happens then you should be just fine.

--------------------------------------------------------
- Trade what you see. Invest in what you believe -
--------------------------------------------------------
Reply With Quote
Thanked by:
  #5 (permalink)
 TheGaryGuy 
Bellevue, WA/USA
 
Experience: Advanced
Platform: NinjaTrader, TOS, TDAmeri
Broker: ThinkOrSwim, TastyWorks.com, TDAmeritrade, Interactive Brokers (soon)
Trading: Index and Stock options, Stocks (seldom), Nadex (just starting), Forex
Posts: 33 since Oct 2012
Thanks Given: 47
Thanks Received: 26


JonnyBoy View Post
The benefits of a UPS cannot be understated, but you will need to power your incoming router from the same UPS power source or that will shut down too if overall power failure occurs to your property. To be honest, in over a decade I can count on one hand the number of times this has happened. And for half of those I wasn't even in a position. So, in all honestly I wouldn't worry about it too much.

At the end of the day your brokers number should be on speed dial. I have used my broker once in a decade to get me out of a position. If you live in a very spotty area for power then maybe you need to be more cautious, but as long as you have a plan of what to do if it happens then you should be just fine.

Several times while actively trading (sim) I have heard "order filled" and "Connection Lost" within seconds of each other and yes I have UPS for all items in my home, but I have had Century Link drop my Gbit Ethernet for no good reason. So yes, I do worry about it much, I only have one house to lose for my country. And yes also I have my smart phone with both NinjaTrader Brokerage and ThinkOrSwim on speed dial. BUT I was actively trading during the flash crash and the phone lines were too busy for my call. I had been up 10s of thousands of dollars on an options trade and ended up losing $700 bucks on a "get me the hell out market order"..

I worked for a computer server manufacturer and we created redundant server configurations for Wall Street. We configured for possible server outages. UPS on everything, dual power grids, Dual network providers and remote server farms for failover incase of natural disaster. There is not one Brokerage that provides that kind of reliability for the retail trader, but I am willing to go there when they show that level of care for our money (the same way they care about their money).

Back to the practical, tactical issues of real time, real money, auto trading on NT 8. Does anyone have experience with the "re-syncing" feature of NT-8? Does it work? any caveats?

Started this thread Reply With Quote
  #6 (permalink)
UweH
Myslenice Poland
 
Posts: 25 since Aug 2019
Thanks Given: 6
Thanks Received: 8


TheGaryGuy View Post
Several times while actively trading (sim) I have heard "order filled" and "Connection Lost" within seconds of each other and yes I have UPS for all items in my home, but I have had Century Link drop my Gbit Ethernet for no good reason. So yes, I do worry about it much, I only have one house to lose for my country. And yes also I have my smart phone with both NinjaTrader Brokerage and ThinkOrSwim on speed dial. BUT I was actively trading during the flash crash and the phone lines were too busy for my call. I had been up 10s of thousands of dollars on an options trade and ended up losing $700 bucks on a "get me the hell out market order"..



I worked for a computer server manufacturer and we created redundant server configurations for Wall Street. We configured for possible server outages. UPS on everything, dual power grids, Dual network providers and remote server farms for failover incase of natural disaster. There is not one Brokerage that provides that kind of reliability for the retail trader, but I am willing to go there when they show that level of care for our money (the same way they care about their money).



Back to the practical, tactical issues of real time, real money, auto trading on NT 8. Does anyone have experience with the "re-syncing" feature of NT-8? Does it work? any caveats?



I have a question: If a lost of connection or power supply is so crucial, that a few seconds or maybe minutes costs you hundred of bucks, then why don’t you rent a piece of server near exchange, which costs you 100-200 bucks monthly and gives you a much better infrastructure with backup recourses,direct fibre cable connection and a remote access? That’s what I would do.


Sent using the NexusFi mobile app

Reply With Quote
Thanked by:




Last Updated on June 28, 2020


© 2024 NexusFi™, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Privacy Policy - Downloads - Top
no new posts