This started off as a simple addition to the Simple Trade Copier, but ended up being a near complete rewrite after safety checks were added and new features added. WARNING >>> The Simple Trade Copier allows for an infinite looping of order copying, instantly getting you into a margin call and crashing Ninja, if not careful.
Master Position and Follower Position is used, because of this trade copier's flexabilith. The Accounts and Instruments can be mixed & matched in any way. For example, the Master Position could be Acct: TT12345 and Instr: /ES 03-24, and the Follower Position can also be Acct: TT12345 but Instr: /MNQ 03-24, so if the accounts are the same then neither is master or follower. The combination of account and instrument creates a Position (for the lack of a better term). While Master Account sounds better, it is inaccurate.
The Account selection and Instrument selection has been "properly" implemented vs. other trade copiers.
How it Works:
- This trade copier only submits market orders to the Follower Positions.
- Market Orders are copied from the Master Position to the Follower Position(s) as soon as the order is submitted by NinjaTrader.
- Limit/Stop Orders are monitored on the Master Position to be Filled. As soon as NinjaTrader acknowledges a fill, a market order is submitted to the Follower Position(s). This can effectively be used to create "ghost" stop-losses for the Follower Position(s).
- The Quantity Ration settings scale up the number of contracts sent to the FP.
- Click the red/green button on the chart to enable/disable trade copying.
Safety Checks:
- Check Follower Positions are Flat: When this is enabled, every time the MP is flat the FP are verified to be flat as well, because it easy to accidentally have the Trade Copier turned off while adding/removing positions to/from the MP. This tool waits 1.5 seconds for the broker to report back that FP are flat. If any FP is not reported as flat at that time, an Account.Flatten() command is issued, and a warning to the trader is issues. If you have automated strategies/systems running on any of the FP independant of this Trade Copier, then disable this option as it will flatten the positions of those automate systems.
- The FP setting are compared to the MP setting for infinite order feedback loops. If one is found the TC disables itself, plays an alert sound, and displays an error message to the CC > Log tab and Alerts Log window.
- Other less lethal checks are done as well, and sends a message to the CC > Log tab and Alerts Log window.
Obviously, you should ONLY use Sim accounts while testing and familiarizing yourself with this tool. And, of course, use at YOUR OWN RISK ! ! !
Happy trading.
Created By | zacharydw00 |
NinjaTrader Version | 8 |
File Size | 78.7 KB |
Create Date | 02/05/2024 |
# of Downloads | 992 |
Importing to NinjaTrader 8 is Easy!
To import your 3rd party app or add-on to NinjaTrader, simply follow these 3 steps:
- Download the app or add-on file to your desktop
- From the NinjaTrader Control Center window, select the menu Tools > Import > NinjaScript Add-On…
- Select the downloaded file from your desktop
Questions?
Visit the NinjaScript File Sharing discussion in the NinjaTrader user forum to interact with fellow traders and the NinjaTrader support team.