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

Head and Shoulder Indicator

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

    #16
    Originally posted by NinjaTrader_MichaelM View Post
    Hello all,

    Having just had a very similar inquiry from a customer I have gone ahead and attempted to figure this out.

    Idea:
    Instead of rewriting every indicator that we want to grab inverse calculations from, we flip/mirror the data series and run the original indicators

    Implementation:
    Use MirrorBars Bar Type to flip the data series and apply the regular indicators

    Issue:
    MirrorBars returns negative OHLC values which many indicators are not coded to work with properly. For example, HSIdentify will not plot at all.

    Solution:
    I have rewritten the MirrorBars Bar Type with an additional parameter called "Positify". You want to set Positify to a value that is higher than the highest traded price in the non-mirrored version of data series you are viewing (to make sure all the bars are above zero). The default value is 3000.

    Caveat:
    The actual prices are not going to mean anything because we added an arbitrary value to them. This will not work with a very specific kind of indicator (that relies on absolute price values rather than price relationships/changes in price). This should however work with 90% of all indicators that are out there including the HSIdentify and HSBasicDef.

    I have attached the new bar type to my post. It replaces MirrorBars so you have to delete the original MirrorBars Bar Type.

    If you want the same results you would get with the original MirrorBars Bar Type just set "Positify" to 0.

    How to add this bar type:
    1. Exit NinjaTrader

    2. Navigate to Documents\NinjaTrader 7\bin\Custom\Type and delete MirrorBar.cs and replace it with the new PosMirrorBar.cs.

    3. Go back one folder to Documents\NinjaTrader 7\bin\Custom and delete NinjaTrader.Custom.dll

    4. Open NinjaTrader

    5. Navigate to Tools -> Edit NinjaScript -> Indicator -> [select any indicator] -> When the code editor pops up, press F5 on your keyboard to recompile

    6. Exit NinjaTrader

    7. Open NinjaTrader

    8. Create a new chart using the PosMirrorBars bar type

    Please let me know if you have any questions.

    Hi Micheal,

    Thanks a bunch for your efforts. Certainly a different approach as I mentioned earlier to Arbuthnot.

    Cheers!
    Last edited by aligator; 09-06-2015, 10:21 AM.

    Comment


      #17
      Hello,

      I think it`s already written.So why re-invent the wheel?
      Attached Files

      Comment


        #18
        Hello outsource,

        Thank you for your input.

        The implementation I provided was not specific to the HSIdentify or HSBasic Def indicators. They were simply used as an example for the concept.

        Please let me know if you have any questions or if I may be of further assistance.
        Michael M.NinjaTrader Quality Assurance

        Comment


          #19
          Originally posted by outsource View Post
          Hello,

          I think it`s already written.So why re-invent the wheel?
          Hi outsource,

          Is that your own modified HSIdentify idncator? Also, is it open source or a compressed .dll file and how much it sells for?

          Thanks.

          Comment


            #20
            Originally posted by aligator View Post
            Hi outsource,

            Is that your own modified HSIdentify idncator? Also, is it open source or a compressed .dll file and how much it sells for?

            Thanks.
            No,it`s ''pvoodoo'' guys indicator and it`s dll file.It goes for $66,afair.I think you can negotiate the open source with Marko,but i`m not sure.You should try.

            Regards

            Comment


              #21
              This is the link:

              Comment


                #22
                Head and Shoulder Indicator - NT8

                Originally posted by NinjaTrader_MichaelM View Post
                Hello outsource,

                Thank you for your input.

                The implementation I provided was not specific to the HSIdentify or HSBasic Def indicators. They were simply used as an example for the concept.

                Please let me know if you have any questions or if I may be of further assistance.
                Hello MichaelM,

                The H&S pattern is statistically the most reliable and time tested price action pattern. Ryan M. created the HSIdentify and HSBasicDef indicators based on April and May 2013 TASC Traders' Tip.

                There is a great deal of interest for a NT8 version of these indicators (i.e. 2900 views of this thread and the number of indicator downloads). I am not sure when Ninja might convert these indicators for NT8 but they are surely missed for NT8 as many active traders use H&S.

                I have converted these indicators for NT8 using the conversion tools on this forum. Both indicators compiled fine but HSBasicDef will generate an error when applied to a chart:

                "Error on calling"OnBarUpdate"method on bar #; Collection was modified; enumeration operation may not execute."

                I can't see why this error is generated even after including some print statements (commented out).

                I am attaching the NT8 version, perhaps someone (either Ninja or a Member) can fix this error and re-post the HSBasicDef indicator. I will then complete the conversion of both indicators and post them here for all.

                Many thanks.
                Attached Files
                Last edited by aligator; 12-07-2016, 11:08 AM.

                Comment


                  #23
                  Originally posted by aligator View Post
                  Hello MichaelM,

                  The H&S pattern is statistically the most reliable and time tested price action pattern. Ryan M. created the HSIdentify and HSBasicDef indicators based on April and May 2013 TASC Traders' Tip.

                  There is a great deal of interest for a NT8 version of these indicators (i.e. 2900 views of this thread and the number of indicator downloads). I am not sure when Ninja might convert these indicators for NT8 but they are surely missed for NT8 as many active traders use H&S.

                  I have converted these indicators for NT8 using the conversion tools on this forum. Both indicators compiled fine but HSBasicDef will generate an error when applied to a chart:

                  "Error on calling"OnBarUpdate"method on bar #; Collection was modified; enumeration operation may not execute."

                  I can't see why this error is generated even after including some print statements (commented out).

                  I am attaching the NT8 version, perhaps someone (either Ninja or a Member) can fix this error and re-post the HSBasicDef indicator. I will then complete the conversion of both indicators and post them here for all.

                  Many thanks.
                  Kind of complex piece of an indicator.But i agree,it would be cool to have it for NT8

                  Comment


                    #24
                    Originally posted by outsource View Post
                    Kind of complex piece of an indicator.But i agree,it would be cool to have it for NT8
                    It is not really that complex, in fact very simple and it converted easily and compiles. The one error needing correction happens when looking for a non-zero period to calculate the value for MAX. Obviously there is a different method for MAX logic in NT8 than NT7, which I can not figure out.

                    All we need is either the Support or a NT Coder here catch this one bug and I can fix the the other twin indicator. This is a great and really useful time tested indicator, and frankly I am surprised that NT will not jump on that instead of converting things like Conner's RSI and variations of moving averages.

                    Oh well, Cheers to whoever pitch in to catch the one bug in the attached file.
                    Last edited by aligator; 12-09-2016, 01:32 AM.

                    Comment


                      #25
                      I`d stick with the NT7 H&S as long as the platform maintained

                      Comment


                        #26
                        Hello all,

                        Thank you for your posts.

                        We will upload the updated HSIdentify and HSBasicDef for NinjaTrader 8 once it has been converted.

                        Comment


                          #27
                          Originally posted by NinjaTrader_PatrickH View Post
                          Hello all,

                          Thank you for your posts.

                          We will upload the updated HSIdentify and HSBasicDef for NinjaTrader 8 once it has been converted.
                          Hello,Patrick

                          what about an inverse HSIdentify?

                          Comment


                            #28
                            Originally posted by NinjaTrader_PatrickH View Post
                            Hello all,

                            Thank you for your posts.

                            We will upload the updated HSIdentify and HSBasicDef for NinjaTrader 8 once it has been converted.
                            PatrickH,

                            Hi. Is there a priority as to when this conversion will take place or it depends on the preference of your programmers?

                            H&S is probably in top 5 % of all indicators in terms of real usefulness and used quite widely. A minor effort to remove the one bug from the NT8 conversion of HSBasicDef that I posted above will make this indicator immediately available to interested members.

                            I vote again for H&S conversion and asking other interested members to vote as well, hopefully get this done soon.

                            Cheers!.

                            Comment


                              #29
                              .........Aye

                              Comment


                                #30
                                Originally posted by NinjaTrader_PatrickH View Post
                                Hello all,

                                Thank you for your posts.

                                We will upload the updated HSIdentify and HSBasicDef for NinjaTrader 8 once it has been converted.
                                Hi PatrickH,

                                I just saw you posted a converted strategy. Any chance you guys convert the HSIdentify indicator please? It has been requested so many times for a long time since the advent of NT8 beta.

                                Thanks a bunch.

                                Comment

                                Latest Posts

                                Collapse

                                Topics Statistics Last Post
                                Started by maybeimnotrader, Yesterday, 05:46 PM
                                4 responses
                                23 views
                                0 likes
                                Last Post maybeimnotrader  
                                Started by frankthearm, Today, 09:08 AM
                                6 responses
                                25 views
                                0 likes
                                Last Post frankthearm  
                                Started by adeelshahzad, Today, 03:54 AM
                                5 responses
                                33 views
                                0 likes
                                Last Post NinjaTrader_BrandonH  
                                Started by stafe, 04-15-2024, 08:34 PM
                                7 responses
                                32 views
                                0 likes
                                Last Post NinjaTrader_ChelseaB  
                                Started by merzo, 06-25-2023, 02:19 AM
                                10 responses
                                824 views
                                1 like
                                Last Post NinjaTrader_ChristopherJ  
                                Working...
                                X