Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Question with ninjascript strategy
Collapse
X
-
Question with ninjascript strategy
While making a new ninjascript strategy, in the conditions and actions set section, I set up certain conditions that result in the action of entering a trade as well as setting variable0 = 1. When a position is not open variable0 = 0. I also set up a condition when variable0 == 1 and when the time series 0 bars ago == the time series 96 bars ago, the action taken is closing any open positions. I thought this would result in closing of any open positions after 96 bars have passed. However while backtesting, this does not seem to be the case, as i have one trade that went over 300 bars. How do I go about setting up a condition and action set that results in any open positions being closed after 96 bars?Tags: None
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by cre8able, Today, 01:16 PM
|
2 responses
9 views
0 likes
|
Last Post
by cre8able
Today, 01:40 PM
|
||
Started by chbruno, 04-24-2024, 04:10 PM
|
3 responses
48 views
0 likes
|
Last Post Today, 01:29 PM | ||
Started by samish18, Today, 01:01 PM
|
1 response
6 views
0 likes
|
Last Post Today, 01:25 PM | ||
Started by WHICKED, Today, 12:56 PM
|
1 response
9 views
0 likes
|
Last Post Today, 01:17 PM | ||
Started by WHICKED, Today, 12:45 PM
|
1 response
11 views
0 likes
|
Last Post Today, 01:08 PM |
Comment