Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Smoothing the input series

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

    Smoothing the input series

    Hi,

    Is it possible to smoothen the input series (Close) of a Range bar with for example a SMA(Close, 4)?
    How would I go about doing this?

    /Thanks

    #2
    Hello nyrn2k,

    Are you asking how to add the SMA indicator to a chart?

    This would provide the smoothing of the data on the chart.

    To add an indicator, right-click the chart > select Indicators > in the Available list select SMA > click add > click OK

    Below is a public link to a video that demonstrates how to add an indicator to a chart.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hi Chelsea,

      No, I want to have the SMA as the input series for the Range bars instead of the close.

      The SMA was just an example, but I believe that a slightly smoothed input series
      would reduce the number of range bars that will be drawn during choppy periods and that would be beneficial to my strategy.

      /Thanks

      Comment


        #4
        Hello nyrn2k,

        The SMA will use the data series on the chart.

        If the data series on the chart are range bars, the range bars will be used for the SMA.
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          Hi,
          I think you missunderstand me...
          I wonder if there is any way of smoothing the input series before the Range bar are drawn.

          I want to minimize the number of bars that are drawn while the instrument is trading in a tight range that is just a little wider than the range bar,
          so that my trend following indicators (sma) react more to price movement and less to time passing while rangebound trading...

          /Thanks

          Comment


            #6
            Hello nyrn2k,

            Ah, the Input Series is where I have misunderstood. The Input Series is used for an indicator and not for a bar type. The bar type will be the series itself that is supplied as an input series to an indicator.

            You are instead wanting to modify the logic for range bars themselves.

            You would need to make a custom bar type (which you could start by copying the

            You will not be able to call an indicator from a custom bar type script. Instead all of the custom logic and calculations will have to be coded directly into the custom bar type script.

            Below I am providing a link to an example custom bar type script for inspiration.
            https://ninjatraderecosystem.com/use...nko-bartype-8/

            Alternatively, you could make an indicator that hides the chart bars and draws its own bars on top. This would be able to call another indicator such as the SMA.
            Below is a link to an example indicator that does this.
            NinjaTrader 8 natively provides Heiken Ashi as a bar type for most common bar types (minute, tick, volume, second, day, week, month, year). This Heiken Ashi indicator is provided for the Range, Renko and any custom bar types that may be added. The indicator performs in the same manner as the NinjaTrader 7 version. 4-27-18 […]


            The NinjaTrader Ecosystem website is for educational and informational purposes only and should not be considered a solicitation to buy or sell a futures contract or make any other type of investment decision. The add-ons listed on this website are not to be considered a recommendation and it is the reader's responsibility to evaluate any product, service, or company. NinjaTrader Ecosystem LLC is not responsible for the accuracy or content of any product, service or company linked to on this website.
            Chelsea B.NinjaTrader Customer Service

            Comment


              #7
              Ok thanks!
              I'll look into this
              Basically I want to filter out highs and lows so no new bars are created when trading is in a range....
              Thank You!

              Comment


                #8
                Hello nyrn2k,

                I think for that you would need a custom bar type that controls when AddBar() is called.
                Chelsea B.NinjaTrader Customer Service

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by argusthome, 03-08-2026, 10:06 AM
                0 responses
                88 views
                0 likes
                Last Post argusthome  
                Started by NabilKhattabi, 03-06-2026, 11:18 AM
                0 responses
                48 views
                0 likes
                Last Post NabilKhattabi  
                Started by Deep42, 03-06-2026, 12:28 AM
                0 responses
                31 views
                0 likes
                Last Post Deep42
                by Deep42
                 
                Started by TheRealMorford, 03-05-2026, 06:15 PM
                0 responses
                34 views
                0 likes
                Last Post TheRealMorford  
                Started by Mindset, 02-28-2026, 06:16 AM
                0 responses
                68 views
                0 likes
                Last Post Mindset
                by Mindset
                 
                Working...
                X