My strategy is fairly simple. I'm new to Ninjatrader but, I've been able to make this work for MT5 and tradeideas.
Basically, I'm looking to create two order buttons (long/short) that send market orders. After clicking the button, the script will use ATR (1.25*ATR for stop and 2.5*ATR for target) to place my stop and target orders.
To calculate order size, I'd like the script to look at my equity and calculate risk from the stoploss. For example, if my equity is $100k and my risk is at .25%, the script should adjust the position size to make my max loss on that trade $250.
Ex.
Current price = $1000
Risk = .25%
Equity = $100K
ATR = 10
Entry = $1000
Stop = $987.5
Target = $1025
Position size = 20 shares = (Equity*Risk) / (Entry-Stop)
Any notes on how I might be able to do this? It seems like it is not possible in ATM.
Thanks!

Comment