Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Market Facilitation Index

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

    Market Facilitation Index

    Hello,

    I created the BW MFI indicator through NinjaScript using the code given on the following thread: http://www.ninjatrader.com/support/f...ad.php?t=19231

    It works just fine, but I wanted to color code the bars based on the four possible outcomes between volume and the BW MFI indicator. In other words, I would like each bar of the BW MFI to be color coded based on the direction that volume went in relation to the BW MFI. (i.e. volume up and MFI up = green, volume up and MFI down = brown, etc).

    Any help would be appreciated.

    P.S. as simple as this may be, I know very little about coding.

    Thanks.

    #2
    Welcome to our forums goldtrader, you can color the bars according to your conditions in the code with the BarColor method - http://www.ninjatrader-support.com/H.../BarColor.html

    Comment


      #3
      Hi Bertrand,

      Thank you for your reply. I tried to fiddle with the code to input the conditional statements but I couldn't make it work. Where in the code do I need to input the conditional color statements?

      I am able to make four colors available for the indicator by using this:

      Add (new Plot(Color.FromKnownColor(KnownColor.Green), PlotStyle.Bar, "VolUpMFIup"));
      Add (new Plot(Color.FromKnownColor(KnownColor.Red), PlotStyle.Bar, "VolDownMFIdown"));
      Add (new Plot(Color.FromKnownColor(KnownColor.Blue), PlotStyle.Bar, "VolDownMFIup"));
      Add (new Plot(Color.FromKnownColor(KnownColor.Brown), PlotStyle.Bar, "VolUpMFIdown"));

      But I still don't know how do tell it to use the specific colors under the different circumstances. Like I said before, my coding ability is next to next to none. I appreciate any help I can get.

      Comment


        #4
        I'm sorry I think I misunderstood your initial request, my pointer was for how to color the price bars on your indicator conditions - if you want to color the indicator plots itself, you would need to use a different plot for each color and then connect those - it's easier than it may sound now, please see for example a sample we've uploaded to show how to change the colors to up / dn / flat for an SMA, the process would be used for your MFI -

        Comment


          #5
          Hey,

          Thanks again for your help. This seems to make a little more sense, but I don't think I am going to be able to do this (I tried applying the BWMFI to the SMA example, but there seems to be too many differences in what I am trying to do). My coding knowledge is just too limited. I know that this would be easy for some one who knows what they are doing. On the other hand, I have wasted several hours trying to do it. Is there any way that I can get this done without having to code it myself? Does NT have people that would do these things? It seems like too minor a job to contact a coding consultant about.

          Thanks,

          Comment


            #6
            goldtrader,

            Unfortunately we do not offer custom programming services. You could try asking a few 3rd party consultants to see if they can get you a reasonable quote.
            Josh P.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            579 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            334 views
            1 like
            Last Post Geovanny Suaza  
            Started by Mindset, 02-09-2026, 11:44 AM
            0 responses
            101 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Started by Geovanny Suaza, 02-02-2026, 12:30 PM
            0 responses
            554 views
            1 like
            Last Post Geovanny Suaza  
            Started by RFrosty, 01-28-2026, 06:49 PM
            0 responses
            551 views
            1 like
            Last Post RFrosty
            by RFrosty
             
            Working...
            X