Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
TailStop for multiple entrees?
Collapse
X
-
Hello relogical,
Thank you for your post.
This is possible by tracking the position size and comparing it to the previous size. Then adjust your Stop Loss price and size based on your desired parameters.
You can use Position.Quantity to track the quantity: http://www.ninjatrader.com/support/h...7/quantity.htm
Please let me know if you have any questions.
-
There are some different ways this could be done and while I don't have an exact example I will get you pointed in the right direction.
For advanced order management use this example to get started. It will show you how to setup an auto breakeven stop order through the use of IOrders. When using IOrders you're able to track your orders individually and are given more flexibility when placing your targets and stops:
The OnOrderUpdate() and OnExecution() methods are reserved for experienced programmers. Instead of using Set() methods to submit stop-loss and profit target orders, you can submit and update them manually through the use of IOrder and IExecution objects in the OnOrderUpdate() and OnExecution() methods. The OnOrderUpdate()
To track the avg fill price you can use this for the whole position: http://www.ninjatrader.com/support/h...l?avgprice.htm
Or this for an individual IOrder: IOrder.AvgFillPrice http://www.ninjatrader.com/support/h...tml?iorder.htm
Let me know if I can further assist.LanceNinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by JoMoon2024, Today, 06:56 AM
|
0 responses
6 views
0 likes
|
Last Post
by JoMoon2024
Today, 06:56 AM
|
||
Started by Haiasi, 04-25-2024, 06:53 PM
|
2 responses
17 views
0 likes
|
Last Post
by Massinisa
Today, 05:32 AM
|
||
Started by Creamers, Today, 05:32 AM
|
0 responses
5 views
0 likes
|
Last Post
by Creamers
Today, 05:32 AM
|
||
Net Change
by Segwin
Started by Segwin, 05-07-2018, 02:15 PM
|
12 responses
1,786 views
0 likes
|
Last Post
by Leafcutter
Today, 05:30 AM
|
||
Started by poplagelu, Today, 05:00 AM
|
0 responses
3 views
0 likes
|
Last Post
by poplagelu
Today, 05:00 AM
|
Comment