NinjaScript risk % of account equity per trade - NinjaTrader | futures trading

Go Back

> Futures Trading, News, Charts and Platforms > Platforms and Indicators > NinjaTrader

NinjaScript risk % of account equity per trade
Started:August 26th, 2014 (07:45 PM) by GgMc Views / Replies:589 / 2
Last Reply:August 27th, 2014 (07:11 AM) Attachments:1

Welcome to

Welcome, Guest!

This forum was established to help traders (especially futures traders) by openly sharing indicators, strategies, methods, trading journals and discussing the psychology of trading.

We are fundamentally different than most other trading forums:
  • We work extremely hard to keep things positive on our forums.
  • We do not tolerate rude behavior, trolling, or vendor advertising in posts.
  • We firmly believe in openness and encourage sharing. The holy grail is within you, it is not something tangible you can download.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community. It's free and simple, and we will never resell your private information.

-- Big Mike

Thread Tools Search this Thread

NinjaScript risk % of account equity per trade

Old August 26th, 2014, 07:45 PM   #1 (permalink)
Trading Apprentice
Futures Experience: Intermediate
Platform: NinjaTrader
Favorite Futures: EURUSD
Posts: 1 since Aug 2014
Thanks: 0 given, 0 received

NinjaScript risk % of account equity per trade

Heya guys,

I've been trying to figure out a method of risking at most 2% of my total account equity per trade. I've been playing around with some strategies and I wanted to figure out if anyone has come up with a ninja script to set the amount risked equal to a % of their account based on their stoploss.

For example, I have a strategy where the stoploss works best at 20 pips and an account with net equity 10,000 USD, I want to limit those 20 pips of EUR/USD to being 2% of my total account or 200$. How that looks to me is:

What risk of 10,000$ is 20 pips = 200$ on EUR/USD?
What about 10,000$ and 40 pips = 200$ on EUR/USD?
Or if 25,000$ account and 20 pips = 500$ on EUR/USD

I greatly appreciate any help with this.

Reply With Quote

Old August 27th, 2014, 05:02 AM   #2 (permalink)
Elite Member
Futures Experience: Intermediate
Platform: NinjaTrader
Posts: 7 since Jun 2010
Thanks: 12 given, 0 received

I've never found something like that. It would be the only thing I would like to have mechanical/automated in my trading. Calculating the position size based on my stop and % I like to risk. But there are some indicators that help to determine the position size and risk like this one:

Unfortunately I don't if you find some non-elite-member indicators out there.

Reply With Quote

Old August 27th, 2014, 07:11 AM   #3 (permalink)
Elite Member
Omer עומר / Israel י
Futures Experience: Master
Platform: NinjaTrader, Proprietary,
Broker/Data: Ninjabrokerage/IQfeed + Synthetic datafeed
Favorite Futures: 6A, 6B, 6C, 6E, 6J, 6N, 6S, ES, CL, ZB
rleplae's Avatar
Posts: 1,457 since Sep 2013
Thanks: 1,066 given, 2,272 received

How i would do it

What about this :

amount = capital * max risk percentage / (pipvalue * number of pips SL)

your example :
suppose you have 1000 and want to risk 2%
maximum loss = 20

equivalent lot = 1000 * 0,02 / (0,0001 X 20)

0,02 : 2 %
0,0001 : pip value
20 : number of pips

result being 10000
you can maximum buy/sell 10000 with a 20 pip stop

check : 20 pips of 10.000 = 10.000 * 0,0020 = 20

be careful, you can have slippage on your stop.

I normally trade futures, and there we talk ticks and contracts.

Reply With Quote
The following user says Thank You to rleplae for this post:

Reply > Futures Trading, News, Charts and Platforms > Platforms and Indicators > NinjaTrader > NinjaScript risk % of account equity per trade

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Upcoming Webinars and Events (4:30PM ET unless noted)

An Afternoon with FIO trader bobwest

Elite only

NinjaTrader 8: Programming Profitable Trading Edges w/Scott Hodson

Elite only

Anthony Drager: Executing on Intermarket Correlations & Order Flow, Part 2

Elite only

Adam Grimes: Five critically important keys to professional trading

Elite only

Machine Learning Concepts w/FIO member NJAMC

Elite only

MarketDelta Cloud Platform: Announcing new mobile features

Dec 1

NinjaTrader 8: Features and Enhancements

Dec 6

Similar Threads
Thread Thread Starter Forum Replies Last Post
Automated account size/risk management? jiorose Elite Automated Trading 3 June 29th, 2014 08:46 PM
Day trade AND Swing trade the same account/broker ? wwwingman Brokers and Data Feeds 8 April 4th, 2014 12:43 PM
Can I use a Ninja demo account to trade with a live web-based account? budfox NinjaTrader 23 July 16th, 2013 07:49 AM
Managing Risk with Equity Curve and Portfolio liquidcci Psychology and Money Management 5 April 24th, 2013 09:51 AM
One Trade Per Bar NINJASCRIPT LastShadowRider NinjaTrader Programming 8 August 2nd, 2011 02:15 PM

All times are GMT -4. The time now is 03:57 AM.

Copyright © 2016 by All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts

Page generated 2016-10-23 in 0.08 seconds with 20 queries on phoenix via your IP