Welcome to NexusFi: the best trading community on the planet, with over 150,000 members Sign Up Now for Free
Genuine reviews from real traders, not fake reviews from stealth vendors
Quality education from leading professional traders
We are a friendly, helpful, and positive community
We do not tolerate rude behavior, trolling, or vendors advertising in posts
We are here to help, just let us know what you need
You'll need to register in order to view the content of the threads and start contributing to our community. It's free for basic access, or support us by becoming an Elite Member -- see if you qualify for a discount below.
-- Big Mike, Site Administrator
(If you already have an account, login at the top of the page)
I'm new to NT8 and trying to learn to build strategies. I have a basic strategy built that is working with 1 contract, and a simple profit target and stop in place.
I would like to know where I can find information on how, if my strategy is set to trade 2 contracts per execution, the stop moves to break even after the first profit target is filled, and then trails the second contract by (x) number of ticks until either second profit target is hit, or the stop is triggered.
Any direction is appreciated.
Bullywig
Can you help answer these questions from other members on NexusFi?
Fire two separate orders with two different strategies associated
first ATM : stop X / target Y
second ATM : stop X + move to B/E or B/E+1, > x ticks and higher target and a trailing stop
I created my strategy within the strategy wizard; is your solution done through the ninja script editor, or can you enter a formula within the strategy wizard for the stop strategy you are suggesting? Thank you for taking the time to answer.
I am afraid you will have to go one level lower and that the strategy manager can not handle that
unless you tell it to do two things and you associate two ATM's
I write strategies in c#, i don't use the strategy manager
if not possible, you could create two identical strategies, that fire two times the same signal
but with a different ATM
in the ATM you can do what you want to do
Can you recommend a good tutorial or video learning scenario for C+ for Ninjascript specifically? I'm a quick study, so I would welcome the opportunity to get more in depth on how these strategies actually work. Thanks again for your assistance.
you need c#, not c++
there are many generic c# courses and then there are the particular design patterns of NT
I'm afraid there is not short cut, you need some time and effort to get to the bottom
I trade just like this as well with 2 contracts and learning the strategy wizard now myself. I belive they mention this concept in the Strategy Wizard training video. Search youtube for NinjaTrader Strategy 301 and they talk about their Order management methods and you can assign tags names to the contract quantity along with trailing. Or go to the help files and read on Order Management.
If (MarketPosition =1) and currentcontracts = Antal
{ProfitTake step1} and close > entryprice + range then begin Sell ("Ptl") Antal - 200000 contracts This bar;
End ;
If (MarketPosition =1)and NegTrend = 1 and currentcontracts = 200000
{ProfitTake step2} and close > entryprice + range * 2 then begin Sell ("Pt2") 100000 contracts This bar;
PtStoppL = Low - 0.00005;
End ;
{*** Exit Long Stopp1 ***}
If (MarketPosition =1)
{Profit stoppL} Then begin
If Close crosses under PtStoppL
then begin Sell ("Pt3") This bar;
End ; End;
you can buy a prepackaged algo that is smart, it will adjust its self based on changing market conditions. there like 80 to 100 bucks... how much is your time worth trying to playing with the software. hope it helps