Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
adx incline with macd
Collapse
X
-
adx incline with macd
i'm trying to backtest the system i've been trading. what i do is enter long when the DI+ is above the DI- and the adx starts to have an incline. the macd must also be above the zero line to enter long. my short entries are just the opposite of this. i have it set up now so that it does this but for some reason it is always in a trade. after i get a long signal it must go 5 points in that direction and then have the adx reset before i could take another signal in the same direction. i dont really understand how to use the set 1, set 2, etc to get the timing right, please help, thanksTags: None
-
Hello,
Thanks for your forum post.
Heres what I would do if it was me. The great thing about NinjaScript is that its so flexible theres always multple ways to accomplish the same thing.
If its me I would setup another Set that is constantly check to see if the Close[0] price is greater then the price that you entered long at by 5 points. If this becomes true then set a Variable0 to 1 for example. For this to work you would need to set a variable when you do EnterLong() to record the entry price so that you can check against it.
Then in your entry conditions you would need to check to make sure that this Variable0 is set to 1 before it can enter.
Then when you also do the EnterLong() set this Variable0 back to 0 so that you wont trade again until you have 5 more points in the direction of the chart before going long again.
Let me know if I can be of further assistance.BrettNinjaTrader Product Management
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
646 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
367 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
107 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
569 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
573 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment