Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Tracking time
Collapse
X
-
Tracking time
I am looking to execute a trade after X amount of time where the high has not been compromised. The idea is check the closing price every minute and compare it to the previous price(high in this case) and if after X time the high has not been overwritten, then begin the trade. I have been looking for a method, but am not finding one. Do people here use C# DateTime structure to track lapsed time ?Last edited by asdfasdf; 04-07-2015, 09:09 AM.Tags: None
-
Hello asdfasdf,
Thank you for your note.
Yes you can use DateTime objects and other C# code in NinjaScript which is written in C#.
Each bar also has a timestamp that is a DateTime object.
This can be accessed with Time[int bars ago].
Below is a link to the help guide on Time.
http://www.ninjatrader.com/support/h...s/nt7/time.htm
Also, if you are running on a 1 minute chart, each bar will close after 1 minute.Chelsea B.NinjaTrader Customer Service
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
638 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
366 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
572 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment