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 condition to exit trade before market closes?
Collapse
X
-
Is there a condition to exit trade before market closes?
Wondering if in NT strategy builder if I can either make sure it doesn’t trade between 3-4PM or if it is 3:30pm and a trade is active then close it/liquidate it?Starts05-01-2022Ends05-01-2022Tags: None
-
Hello MatthewLesko,
Yes, the Strategy Builder is able to have time conditions. See the Time section in the Condition Builder.
Below is a link to the 'Automate Your Trading with NinjaTrader's Strategy Builder' which discusses time conditions.
NinjaTrader's Strategy Builder empowers traders of all levels with point-and-click automated trading strategy development. Create your own advanced automated...
The Strategy Builder also has the Strategy > Position available if you want to check the position is long or short.
Also, below is a link to a forum post with helpful information about getting started with NinjaScript.
Chelsea B.NinjaTrader Customer Service
- Likes 1
-
Thanks is there a way then to exit a trade if it's about to be 4PM? Like exit any open positions by 3:5PM CST for example?
Comment
-
Hello MatthewLesko,
You can make a condition in Conditions and Actions in the Strategy Builder to check the time is after 3:50PM and before 4:00PM,.
For the Action, you can call ExitLong/ExitShort.
The video Chelsea provided describes Time Filters and using the Strategy Builder.
You can also follow the direction for setting up Time Filters below:
https://ninjatrader.com/support/help...ateTimeFilters
ExitOnSessionClose may also be used, along with ExitOnSessionCloseSeconds, but we also suggest using Time Filters to control your entry conditions, since an entry order can still be calculated after ExitOnSessionClose starts.
ExitOnSessionClose - https://ninjatrader.com/support/help...sestrategy.htm
ExitOnSessionCloseSeconds - https://ninjatrader.com/support/help...oseseconds.htmLast edited by NinjaTrader_Jim; 05-06-2022, 02:16 PM.JimNinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by pibrew, Today, 06:37 AM
|
0 responses
4 views
0 likes
|
Last Post
by pibrew
Today, 06:37 AM
|
||
Started by rbeckmann05, Yesterday, 06:48 PM
|
1 response
14 views
0 likes
|
Last Post
by bltdavid
Today, 05:43 AM
|
||
Started by llanqui, Today, 03:53 AM
|
0 responses
6 views
0 likes
|
Last Post
by llanqui
Today, 03:53 AM
|
||
Started by burtoninlondon, Today, 12:38 AM
|
0 responses
11 views
0 likes
|
Last Post Today, 12:38 AM | ||
Started by AaronKoRn, Yesterday, 09:49 PM
|
0 responses
16 views
0 likes
|
Last Post
by AaronKoRn
Yesterday, 09:49 PM
|
Comment