Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
getting open positions
Collapse
X
-
getting open positions
We are finishing up a strategy and are coding position sizing based on Kelly Formula. In our calculations we would also like to use in the formula "number of current open positions" , Is there a function to get the open positions? We are using IB. Thanks for any help.Tags: None
-
Hello,
There is not a supported function to get all open positions on all instruments.
Each strategy instances will only be aware of the positions on that strategy. There is no cross communication between strategy instances and there is no way to read the position directly from another strategy.MatthewNinjaTrader Product Management
-
We have studied extensively over our backtesting the amount of concurrent positions open in order to determine ASR (account size required) for each strategy so we have decided to incorporate the same logic in to our position sizing algo. So we simply need a count of open positions at the time a new signal is triggered. The position values like P&L, share quantity, etc etc is not relevant for the calculation. We just need to know the quantity of open positions. Thanks.
Comment
-
Hello,
If this is all from the same strategy instance, you can get it using a Position object.
Please see our Help Guide on these objects for more information:
As long as you have one strategy instance that is opening positions on these instrument, you can obtain the information. If you have separate instances running on different instruments, the position information cannot be shared.MatthewNinjaTrader Product Management
Comment
-
Hello,
I was having the same problem with the lack of inter-strategy communication that NinjaTrader offers. So, we went out of the bos to create a small algorithm to workaround this issue. Please read this article:
Feel free to contact us if you need this implemented in your strategies.
Thanks
Umer
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
673 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
379 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
111 views
0 likes
|
Last Post
by Mindset
02-09-2026, 11:44 AM
|
||
|
Started by Geovanny Suaza, 02-02-2026, 12:30 PM
|
0 responses
577 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
582 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment