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!
See more
See less

Partner 728x90

Collapse

HMA inconsistent with other platforms

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

    HMA inconsistent with other platforms

    I am working with a friend on testing the Hull Moving Average. He uses a different trading platform and charted the HMA in a 1 day 60 period setting. I then plotted the same settings in Ninja Trader, but it is clear that the other platform has a much more smoothed HMA than what I get when plotting in NT. He confirmed with another friend who uses a third platform, and their two HMA calculations matched.

    I looked into the source code of the indicator, but did not see anything immediately wrong. Has anyone run into a similar problem? Perhaps I'm overlooking a setting?

    Any help would be appreciated.

    #2
    Hello eplum,

    Thank you for your post and welcome to the NinjaTrader forums!

    Looking at the source code is a good way to identify any potential differences. You can also see that the HMA is built using WMA and you can compare the calculations for this as well.

    There may be differences in chart data. Not all indicators will match up across platforms, even if the calculations are identical.
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Hi Ryan,

      Thanks for the reply. I am a bit surprised to hear you say;

      "There may be differences in chart data. Not all indicators will match up across platforms..."

      Maybe I should be more clear - the HMA values differ by a large amount. The NT values cause the HMA curve to whipsaw (moving from declining to inclining) many times, while the HMA calculated by the other two platforms yields a steady incline, and no whipsaw. This example I'm referring to is a basic 1 year chart of the SPY.

      I will compare the WMA between the two platforms as well...

      Comment


        #4
        Thank you for the observations. Comparing values across different trading platforms might not indicate an issue.

        You can look at the source code for all system indicators. Please let us know if you identify an issue with the calculation method for HMA or WMA. The calculations are not proprietary so you should be able to compare our method with commonly accepted definitions for these.
        Ryan M.NinjaTrader Customer Service

        Comment


          #5
          I found that changing NT HMA code slightly also reduced its LAG considerably. NJ HMA code is definitely to be improved upon.

          Comment


            #6
            Originally posted by warpoff View Post
            I found that changing NT HMA code slightly also reduced its LAG considerably. NJ HMA code is definitely to be improved upon.
            Could you please elaborate

            - whether NinjaTrader correctly implements the Hull MA
            - what are the changes that you made
            - and why you think that the NinjaTrader HMA code can be improved

            I am interested in knowing the details.

            You can find a variety of implementations of the Hull MA in the traders tips section from December 2010 as per link below:

            Traders' Tips, a collection of code provided by developers to help implement trading ideas and techniques presented in the pages of Technical Analysis of Stocks & Commodities Magazine.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by xiinteractive, 04-09-2024, 08:08 AM
            2 responses
            10 views
            0 likes
            Last Post xiinteractive  
            Started by Irukandji, Today, 09:34 AM
            1 response
            3 views
            0 likes
            Last Post NinjaTrader_Clayton  
            Started by RubenCazorla, Today, 09:07 AM
            1 response
            5 views
            0 likes
            Last Post RubenCazorla  
            Started by TraderBCL, Today, 04:38 AM
            3 responses
            25 views
            0 likes
            Last Post NinjaTrader_Jesse  
            Started by WeyldFalcon, 08-07-2020, 06:13 AM
            11 responses
            1,423 views
            0 likes
            Last Post jculp
            by jculp
             
            Working...
            X