Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Help Needed with creating indicator

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    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.
    Attached Files

    #2
    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;
    }

    Comment


      #3
      313724 interesting indicator, is it working now?

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by CarlTrading, 03-31-2026, 09:41 PM
      1 response
      79 views
      1 like
      Last Post NinjaTrader_ChelseaB  
      Started by CarlTrading, 04-01-2026, 02:41 AM
      0 responses
      40 views
      0 likes
      Last Post CarlTrading  
      Started by CaptainJack, 03-31-2026, 11:44 PM
      0 responses
      63 views
      2 likes
      Last Post CaptainJack  
      Started by CarlTrading, 03-30-2026, 11:51 AM
      0 responses
      63 views
      0 likes
      Last Post CarlTrading  
      Started by CarlTrading, 03-30-2026, 11:48 AM
      0 responses
      54 views
      0 likes
      Last Post CarlTrading  
      Working...
      X