Hey everyone, I have created this indicator (attachment below) and I'm running into a little bit of a problem. As you can see in the image attached, I have MACD and my own indicator. The blocks of color line up with MACD perfectly, though the line does not. For example, at 12:00 the block of color is red, lining up with MACD, but the line is turns white and stays like that for a couple more candles. I have marked the 0.5 and -0.5 on the MACD because that is where I want the line on my indicator to start collecting and outputting data. This indicator is what I have done so far. I have also included with the picture the script in a zip file. Again, I'm not a professional programmer but this is what I've done so far. I really appreciate if you could help, please let me know if this idea is possible.
Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Help Needed with creating indicator
Collapse
X
-
Help Needed with creating indicator
Hey everyone, I have created this indicator (attachment below) and I'm running into a little bit of a problem. As you can see in the image attached, I have MACD and my own indicator. The blocks of color line up with MACD perfectly, though the line does not. For example, at 12:00 the block of color is red, lining up with MACD, but the line is turns white and stays like that for a couple more candles. I have marked the 0.5 and -0.5 on the MACD because that is where I want the line on my indicator to start collecting and outputting data. This indicator is what I have done so far. I have also included with the picture the script in a zip file. Again, I'm not a professional programmer but this is what I've done so far. I really appreciate if you could help, please let me know if this idea is possible.Tags: None
- Likes 1
-
Hi, thanks for posting. The script works on my end. Use the Print method to print out data from the script to make sure it's doing what you want e.g.
Code:if ((MACD1.Default[0] <= 0.5) && (MACD1.Default[0] >= -0.5)) { Print(MACD1.Default[0]); //this will print out the value of the MACD to the output window, confirming this condition becomes true. PlotBrushes[0][0] = Brushes.White; }
Chris L.NinjaTrader Customer Service
-
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by drnoggin, Today, 12:19 PM
|
1 response
13 views
0 likes
|
Last Post Today, 12:46 PM | ||
Started by synthhokie, Today, 12:00 PM
|
1 response
16 views
0 likes
|
Last Post Today, 12:31 PM | ||
Started by moneyexe, Today, 11:22 AM
|
1 response
12 views
0 likes
|
Last Post Today, 11:32 AM | ||
Started by stevec1824, Today, 11:00 AM
|
2 responses
8 views
0 likes
|
Last Post
by stevec1824
Today, 11:32 AM
|
||
Started by sofortune, Today, 10:05 AM
|
2 responses
14 views
0 likes
|
Last Post
by sofortune
Today, 10:58 AM
|
Comment