I am quite new to NeuroShell Trader and the forum, so I hope someone could help me. Due to work related compliance reasons I need to keep a minimum period of 5 trading days between an opposite transaction (so in case of a buy I need to wait 5 trading days before I can sell my position and the other way around). Anyone any idea how I can implement this in NST?
Hi there , well i guess you can do it this way .
Buy order triggered . Day 1
In the Long exit ,
- Whatever is your exit condition
- Bars since order filled >=5
Now you have you have the choice of using a boolean expression
AND 2 . or put in both conditions and select both orders to be used and make
2 conditions have to be used .
eg 1. Price Target
2. Number of Bars since filled >=5
If that is a market order it will be executed on the next open .which is day 6
Mark both inputs to be used ,
Ok, thanks Michael, I’m going to take a look at it and try to implement something like that.
Note on the second trade it took 8 bars.
Thanks very much, Michael, much appreciated!3 years, 6 months ago Ward Systems Group SupportKeymaster
In the Trading Strategy Advanced tab, there is a parameter you can set called “Shortest desired trade span” that you could set to 5 days.
There is a similar option on the Optimization tab of the prediction wizard.3 years, 5 months ago MarcelBParticipant
Ok, thx very much! Will take a look at it.3 years, 5 months ago MarcelBParticipant
I’ve tried this but apparently it’s closing positions already within the ‘Shortest desired average trade span’ (which is in my case 175 bars).
Could it be maybe that my data file is has 1 minute bars and the frequency of the chart is 15 minutes? I’ve added two files which shows the Trading Strategy Parameters and the trade by trade overview. According to the parameter I’ve used (175 bars) I would assume that the shortest desired average trade span would be at least 6.7 days but as you can see in the trade by trade report it appears that trades are closed within 1 day (see i.e. on 13/04/2020). Does anyone have an idea what’s going wrong?
And how is the ‘Shortest desired Average trade span’ defined? I need to have 5 days between the last trade and the opposite transaction I want to do. So entering 3 long positions with 1 day is no problem but then I have to wait at least 5 full trading days before I am allowed to exit my position (work related compliance rules ). And then I need to wait another 5 days before I am allowed to enter again a long position. So I wondering what the Average Trade Span means, does it count the average trade span already from the first entry or from the last, because I need the last in order to be sure that there is at least a 5 trading day period between opposite transactions.
You must be logged in to access attached files.3 years, 5 months ago michaelParticipant
Try using the bars since order filled .
Use the relational A > B
Bars since order filled > 175 , Then you can exit a trade. That will take the last position into account, it is based on the last order filled.
Bars since exit filled > 175 . Then you can enter a new trade.
Remember to fix the 175 bars .
The question we need answering is how to enter a new trade that is not input by the model . If that was your first trade , to get the ball rolling so to speak.
You need to use the rules if A then do X or do Y
If A do A, if B do B , otherwise do C or nest them .3 years, 1 month ago Ward Systems Group SupportKeymaster
The bars since orders filled parameter is based on the chart frequency. If the trading strategy is based on a smaller time frame, use Bars Since Exit Filled if it matches the timeframe you want to trade.
You must be logged in to reply to this topic.