or maybe to manipulate a MIT into a trail for the same purpose?
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Trailing Buy Market order?
Collapse
X
-
Trailing Buy Market order?
Is there a method to submit a trailing buy order for back-testing? manual or otherwise....
or maybe to manipulate a MIT into a trail for the same purpose?Tags: None
-
Hello HaveGunsWillTravel,
The SetTrailStop() method submits a trail stop.
Note, this will update on bar close unless the order is submitted to a 1-tick series for intra-bar granularity (with TickReplay).
This can also be controlled with logic with exit orders or an MIT order.
Chelsea B.NinjaTrader Customer Service
-
Thank you, could you add a feature request ID# for 'Enter Long Position with Trail...' into strategy builder? Thank you.
Comment
-
Hello HaveGunsWillTravel,
I'm not certain I am understanding. How would this be different than the SetTrailStop added on the Stops and Targets page of the Strategy Builder?
Are you wanting to move the page this is on?
Below is a link to the 'Automate Your Trading with NinjaTrader's Strategy Builder' training video if you are unfamiliar with the Strategy Builder.
Chelsea B.NinjaTrader Customer Service
Comment
-
I do not want to exit with a stop (as with stops and targets), but I want to test entering with a trailing buy... and be able to back test it. Entering with a trail is not an option right now.
Example:
signal happens:
place a trail just above price, to buy, so that I can test buying into a retrace.
Am I making sense? As far as I understand, using trails in the 'stops and targets' section will not facilitate this as of now, it only offers "Exit XYZ trail..."
Comment
-
That would simply be a limit order... Still need the part that 'trails' or changes the order price as the price moves. I should have been more specific, I thought that part was implied.Originally posted by ezrollin View PostEnterLongLimit(DefaultQuantity, (GetCurrentBid(Default input) -5), "");
It wouldnt be a "trailing buy" it would be a limit buy on the bid (cheaper) minus whatever distance you want in ticks, pips, percent, etc...
https://www.interactivebrokers.com/e...et-touched.php
Comment
-
Hello HaveGunsWillTravel,
A "tailing order" would be an order that updates and gets closer to the current market price.
ezrollin is stating that if you call EnterLongLimit a Buy limit order will be placed at that price. As the market moves, GetCurrentBid will return new values, and the but limit order will always stay 5 points from this price.
If EnterLongLimit is called with the same entry signal name, and the order is active, the order will be updated. This is how you can make a "trailing entry" or an entry that chases after the current market price.
So, you could consider implementing your own trailing/chasing behaviors using Conditions and Actions to check...
> If the current market price increased X ticks from the last price the stop was updated
and do the following actions...
> Update a variable that represents the last price the entry was moved
> Update a variable that represents the price that the entry order should lie.
Then you can have another condition set check if you are Flat, and then call EnterLongLimit with the desired limit price.
Then you can have another condition set that checks if you are Long and then resets the temporary variables.
Market Position comparisons - https://ninjatrader.com/support/help...ionComparisons
Variables can be created in Inputs and Variables page of the Strategy Builder, and can be read in Conditions and set in Actions.
We look forward to assisting.
- Likes 2
Comment
-
Thats exactly what I meant. You can have your limit buy order stay away from the current bid price and flirt with staying away and trying to buy it at the bottom and it'll only fill if huge orders come in to smack the price down into that cheaper price. Then you've bought into the low of the wick. thanksOriginally posted by NinjaTrader_Jim View Postezrollin is stating that if you call EnterLongLimit a Buy limit order will be placed at that price. As the market moves, GetCurrentBid will return new values, and the but limit order will always stay 5 points from this price.
If EnterLongLimit is called with the same entry signal name, and the order is active, the order will be updated. This is how you can make a "trailing entry" or an entry that chases after the current market price.
- Likes 1
Comment
-
Ok, I was under the impression getting the bid as the variable would move the order back up also if the bid increased?...I will play with it to see how it works because I am still not completely understanding what prevents the limit from moving back up by reading this. Since the 'getbid' would be on each bar update right? then update the limit to be '5' above? Thanks for the help.Originally posted by ezrollin View PostThats exactly what I meant. You can have your limit buy order stay away from the current bid price and flirt with staying away and trying to buy it at the bottom and it'll only fill if huge orders come in to smack the price down into that cheaper price. Then you've bought into the low of the wick. thanks
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by NullPointStrategies, Yesterday, 05:17 AM
|
0 responses
56 views
0 likes
|
Last Post
|
||
|
Started by argusthome, 03-08-2026, 10:06 AM
|
0 responses
132 views
0 likes
|
Last Post
by argusthome
03-08-2026, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
73 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
45 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
49 views
0 likes
|
Last Post
|

Comment