Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

CCI Special Indicator Need Help

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

    CCI Special Indicator Need Help

    Can anybody help me find the following:

    An indicator that is just a solid bar that prints a color when the CCI is above or below a certain threshold...i.e. when it is above 150 print a color or below 150 print a color and then the color goes away once CCI moves back within the 150 value towards 0?

    Thank you.

    Also, I screwed up my Gann HiLo indicator like an idiot and can't find another one. I thought there would be one on this forum...

    Thank you

    #2
    Hello jmflukeiii,
    As part of my training I have created a small script for you. The attached indicator draws a blue/red bar depending on the cci threshold parameter. If you need anything more you can get in touch with any of our NinjaScript Consultants http://www.ninjatrader.com/partners#...pt-Consultants

    A quick search gave me this link regarding the GannHiLo indicator http://www.ninjatrader.com/support/f...ad.php?t=11509
    If it is not the one you are looking for then do search the forum or maybe any community member can guide you to the same.

    Please let me know if I can be of any further help.

    Regards,
    Joydeep.
    Attached Files
    Last edited by NinjaTrader_Joydeep; 12-16-2011, 06:06 AM.
    JoydeepNinjaTrader Customer Service

    Comment


      #3
      Thank you very much, I really appreciate it. I guess my explanation was a little vague however as I didn't meant the color would go away for ever. I meant, during the period where the CCI was over or under a certain threshold, the indicator would paint that color and it would remain. Once the CCI left the threshold, the indicator would stop painting any color (or just paint a color that the user determines to match their background so it doesn't appear anymore). I do really appreciate the help though.

      Comment


        #4
        Hello jmflukeiii,
        I have reconfigured the indicator. Please download the same again from my previous post.

        Please do let me know if its ok or not.

        Regards,
        Joydeep.
        JoydeepNinjaTrader Customer Service

        Comment


          #5
          That's great! Thank you so much.

          The only issue I see is that I changed the color when adding it to a chart, but it still prints blue.

          In case you were curious, I use to it to find quick reversal trades on a 5 second forex charts using 375 as the period setting. The bars are much cleaner and much easier to read than looking at a squigly 5 second CCI line graph.

          Thanks again

          Comment


            #6
            Hello jmflukeiii,
            The colors are hard coded. If you want further customization you can write to one of our NinjaScript Consultants http://www.ninjatrader.com/partners#...pt-Consultants

            Happy trading, and please do let me know if I can be of further help.

            Regards,
            Joydeep.
            JoydeepNinjaTrader Customer Service

            Comment


              #7
              Thank you, no problem, I just changed it myself.
              Again, I appreciate the help!

              Comment


                #8
                Hello jmflukeiii,
                Glad you could do it yourself.

                You can refer to this sample code on custom color for further reference


                Please do let me know if I can be of any further help.

                Regards,
                Joydeep.
                JoydeepNinjaTrader Customer Service

                Comment


                  #9
                  Ha, well, pretty much all I know how to do is find a color and change it to a different color unfortunately. But at least I've got that down now....

                  Comment


                    #10
                    Hello jmflukeiii,
                    Glad, atleast you have a working indicator as per your requirement.

                    Please do let me know if I could assist you any further.

                    Regards,
                    Joydeep.
                    JoydeepNinjaTrader Customer Service

                    Comment


                      #11
                      Maybe you could help me out with this....

                      How could I create another of the same indicator basically, but adjust the colors for it so I can run too concurrently (in separate panels) for different thresholds with different colors. So for example, I use one panel to distinguish overbought/oversold at a 200 threshold, and then another panel I use a simple red or green to denote whether the CCI is on top of the 0 line or on bottom of the 0 line?

                      Thank you!

                      Comment


                        #12
                        Actually nevermind, I figured it out! Thanks for getting me started, this has been a great learning experience on doing a little, albeit very minor, programming.

                        Now the only thing left to figure out is how to make it so you can have varying colors for different thresholds... for example, above 0, cyan, above 100, green. And also, below 0, magenta, below -100 red. Maybe I'll try to fiddle with it and see if I can figure out.... (don't hold your breath though...)
                        Last edited by jmflukeiii; 12-16-2011, 02:50 PM.

                        Comment


                          #13
                          Hi jmflukeiii,

                          You could create multicolored plots by conditionally assigning PlotColors property. This sample can help show a technique:

                          Ryan M.NinjaTrader Customer Service

                          Comment


                            #14
                            Thanks for the response. Is there anyway to easily plug in a Williams %R into this instead of a CCI, and have different colors print when the oscillator is above -20 and below -80, and also a third color when the oscillator is inbetween the extremes?

                            Comment


                              #15
                              jmflukeiii,

                              Yes, essentially you can replace CCI(period)[0] with WilliamsR(period)[0] in any DataSeries.Set() fields or if statements.

                              In that CCIBars indicator, the if statements can be changed :

                              if (CCI(cciPeriod)[0] > cciThreshold)

                              to

                              if (WilliamsR(Period)[0] > Threshold)

                              Please let us know if you require additional assistance.
                              Adam P.NinjaTrader Customer Service

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by andrewtrades, Today, 04:57 PM
                              1 response
                              5 views
                              0 likes
                              Last Post NinjaTrader_Manfred  
                              Started by chbruno, Today, 04:10 PM
                              0 responses
                              3 views
                              0 likes
                              Last Post chbruno
                              by chbruno
                               
                              Started by josh18955, 03-25-2023, 11:16 AM
                              6 responses
                              436 views
                              0 likes
                              Last Post Delerium  
                              Started by FAQtrader, Today, 03:35 PM
                              0 responses
                              7 views
                              0 likes
                              Last Post FAQtrader  
                              Started by rocketman7, Today, 09:41 AM
                              5 responses
                              19 views
                              0 likes
                              Last Post NinjaTrader_Jesse  
                              Working...
                              X