Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Trailing Stop not working via Strategy Wizard
Collapse
X
-
CalculationMode.Percent not working
I can get the TS to work with a mode of Ticks and an amount, but I can't get it to work with Percent...
For example:
SetTrailStop("", CalculationMode.Percent, 4, false);
With that I get the following error in the log:
Calculated trail stop price for strategy 'crossTS2/...581' was smaller/equal 0. No trail stop order placed.
Comment
-
Setting for trailing stop
I have just started trying out writing some strategy, and is running into some trouble with trailing stop. I have tried both tick & percent, and tried both True & false, but it is apparently not functioning. I use some very obvious setting, like 5 ticks, 1% (0.01) for percent. Any idea where it could have been wrong?
Comment
-
Thanks for your prompt reply.
Let me try to elaborate what I wanted to achieve. Say after I enter a long position, the price rise. I want to let my position to grow as price continue its rise; and if the price stop rising, and reverse by a fixed %, I would like to stop out. In the strategy analyser, I have tried use some value (like 1%, 5 ticks) that should sure trigger the stop for my initial trial, but it didn't trigger at all, which is very puzzling. I have been doing this while I trade stocks, so I feel it is logical. Hope to get some insight from you.
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by argusthome, Yesterday, 10:06 AM
|
0 responses
20 views
0 likes
|
Last Post
by argusthome
Yesterday, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
18 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
14 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
9 views
0 likes
|
Last Post
|
||
|
Started by Mindset, 02-28-2026, 06:16 AM
|
0 responses
40 views
0 likes
|
Last Post
by Mindset
02-28-2026, 06:16 AM
|

Comment