Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Is there a function that allows you to block trading on the account?
Collapse
X
-
Hi Goolden,
there is a free user app share. Maybe this will help you.
This strategy will close any open positions and stop trading for the current day if your daily P/L reaches a set negative or positive value. There are simpler ways to accomplish a daily PL limit if you stop and restart your strategy every trading day, but those ways don’t always work when back testing over […]
Credits to "algotrading".
Regards
Tradeer
-
Hello Goolden and Tradeer,
Thank you for your posts.
It's important to note a couple of things here. I wouldn't suggest the strategy that Tradeer posted, as it appears it just enters long or short randomly if the strategy is between the open and close times specified and then exits when it hits the loss or profit limit.
There's not a way to keep manual entries from being made after a certain PnL is reached. Generally strategies are self-contained, so the above could be used as an example of how to build a daily PnL limit into a strategy, but the strategy PnL isn't the same as the PnL for your whole account.
Here's an example of using trade performance statistics to stop a single strategy from trading that's a little easier to follow than the one Tradeer posted:
If you're wanting something that will monitor the PnL for all strategies you're running on your account and stop after a specific Account PnL, such a project would likely be best made as an Add On so that not only would it not disable like a strategy but also that it could watch all account position, execution, and order events as needed.
Please refer to the following links for details on the items you will need to begin this project:- Add On: https://ninjatrader.com/support/help...-us/add_on.htm
- Add On Development Education: https://ninjatrader.com/support/help...t_overview.htm
- Account: https://ninjatrader.com/support/help...ount_class.htm
Please let us know if we may be of further assistance to you.
Kate W.NinjaTrader Customer Service
- Likes 1
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by samish18, 04-17-2024, 08:57 AM
|
16 responses
55 views
0 likes
|
Last Post
by samish18
Today, 03:30 PM
|
||
Started by arvidvanstaey, Today, 02:19 PM
|
3 responses
9 views
0 likes
|
Last Post Today, 03:23 PM | ||
Started by jordanq2, Today, 03:10 PM
|
2 responses
8 views
0 likes
|
Last Post
by jordanq2
Today, 03:23 PM
|
||
Started by traderqz, Today, 12:06 AM
|
10 responses
18 views
0 likes
|
Last Post
by traderqz
Today, 02:49 PM
|
||
Started by algospoke, 04-17-2024, 06:40 PM
|
5 responses
47 views
0 likes
|
Last Post Today, 02:36 PM |
Comment