Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Where to start if I want to create a strategy on a trading set-up?
Collapse
X
-
Hi Ryan and Koganam
I stopped running the script for an hour now. Continue getting hundreds of email alerts every 5-10 minutes. Guess it may take the system some hours to dry up the alerts ...
Too scary to add a SendMail alert when I don't know how to program it properly. I will do more research on boolean flag after overcoming the alert dilemma. Thank you.
Comment
-
I just hope that you did not have COBC = false in that script, or you may have well sent in excess of 1 million emails.Originally posted by belecona View PostHi Ryan and Koganam
I stopped running the script for an hour now. Continue getting hundreds of email alerts every 5-10 minutes. Guess it may take the system some hours to dry up the alerts ...
Too scary to add a SendMail alert when I don't know how to program it properly. I will do more research on boolean flag after overcoming the alert dilemma. Thank you.
Comment
-
Sorry it's not a strategy. It's a signal indicator that I experimented with a SendMail alert. With the looping code, it generated 500,000+ mail alerts and finally stopped after 4 hours - gosh!
Since it's a nice-to-have feature, I am not going to play with the indicator anymore. Do not have a big heart to accommodate another half a million or millions of alerts ..
Comment
-
The safe way to code anything that will generate output other than to the chart screen, is to replace the generating function with another that Print()s to the Output window or throws an alert. That way, if something goes wrong, the worst that can happen is that your local computer get overwhelmed.Originally posted by belecona View PostSorry it's not a strategy. It's a signal indicator that I experimented with a SendMail alert. With the looping code, it generated 500,000+ mail alerts and finally stopped after 4 hours - gosh!
Since it's a nice-to-have feature, I am not going to play with the indicator anymore. Do not have a big heart to accommodate another half a million or millions of alerts ..
Once you have that working correctly then you replace your output generator, whatever it may be, with the SendMail function, which will then behave exactly as your safe test function did, in terms of how much output it will generate.
Comment
-
Hi Koganam
Thanks for your tips.
I really don't know what happened. My Up/Down Arrows and audio alerts using the same conditions have been working fine for weeks. Yet when I just added the SendMail code right beneath one of them, it's getting wild. Let me calm down a little (getting over the unexpected chaos last week) and may give it a second look
Comment
-
If a draw object draws over itself, you will not notice that difference.Originally posted by belecona View PostHi Koganam
Thanks for your tips.
I really don't know what happened. My Up/Down Arrows and audio alerts using the same conditions have been working fine for weeks. Yet when I just added the SendMail code right beneath one of them, it's getting wild. Let me calm down a little (getting over the unexpected chaos last week) and may give it a second look
Alert() has a bulit-in reset that ensures that it does not fire on every tick, but only after the reset time. Have a reset longer than the candle time, and in effect, you have an Alert() that can trigger only once, so everything looks and sounds fine, hiding the fact that because COBC = false, you may be generating many things, that just visually and audibly do not force notice.
You have to make a programmatic arrangement to ensure that the email is sent only once per occurrence.
Comment
-
Hi Ryan
Believe your day has been going well. I need to do testing on some breakout systems. Since I have not created any indicators/strategies based on Minute charts, I would appreciate your kind assistance in directing me to find some NinjaTrader samples that may cover the following:
1. Identify High/Low of a specified timeline. For example, draw 2 horizontal lines on the chart to highlight the High/Low for 9:30-9:45 am EST.
2. Instead of changing the Start/End time within the indicator's script, how can I have them on the indicator's parameters so that I can change them easily? If it's too complicated, I'm happy to accomplish Item 1 above and manually change the time.
3. Once I have the High/Low (per Item 1), how can I reference them for a pair of Buy/Sell orders waiting to be filled when price breaks High/Low in a strategy?
Thank you for your guidance. Have a nice afternoon.
Beth
Comment
-
Hello,
While I'm not familiar with any ready made indicators you could take a look at the "CurrentDayOHL" indicator that comes with Ninja trader and apply a time filter to a custom version of it.Originally posted by belecona View PostHi Ryan
1. Identify High/Low of a specified timeline. For example, draw 2 horizontal lines on the chart to highlight the High/Low for 9:30-9:45 am EST.
Along with the above you could use a time filter in the script and then define a user input so that you can change the times used.2. Instead of changing the Start/End time within the indicator's script, how can I have them on the indicator's parameters so that I can change them easily? If it's too complicated, I'm happy to accomplish Item 1 above and manually change the time.
You would put something like the following in the properties section of the script to add a user input:
http://www.ninjatrader.com/support/h...ries_class.htmCode:[Description("Starting time")] [GridCategory("Parameters")] public int MyStartTime { get { return myStartTime; } set { myStartTime= Math.Max(1, value); } }
Similarly to how you would use CurrentDayOHL() except with your custom indicator's name (see this link for examples)3. Once I have the High/Low (per Item 1), how can I reference them for a pair of Buy/Sell orders waiting to be filled when price breaks High/Low in a strategy?
Please let me know if I can be of further assistance.LanceNinjaTrader Customer Service
Comment
-
Hello,
Yes, you can find reference samples here: http://www.ninjatrader.com/support/f...ead.php?t=3220
You can find Tips here: http://www.ninjatrader.com/support/f...ead.php?t=3229
You can find file sharing here: http://www.ninjatrader.com/support/f...splay.php?f=37
Please let me know if I can be of further assistance.LanceNinjaTrader Customer Service
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
649 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
370 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
109 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
574 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
576 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment