Announcement

Collapse
No announcement yet.

Polarized Fractal Efficiency

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

  • Polarized Fractal Efficiency

    Does anyone have this coded as an EFS? i have seen code for Tradestation and MetaStock for this indicator and many traders that I chat with speak highly of this study. Link below - shows example code for this study available on the I-Net.


  • #2
    Hi fasc76,

    You may want to check out this EFS Study written by TSSupport. I believe this may be what you are looking for. Hope this helps.

    Comment


    • #3
      fasc76
      See this post
      Alex

      Comment


      • #4
        Them guys is fast posters. Beat me to posting the link.

        One note on this version: If you are familiar with PFE then you will know that the buy and sell bands set at 50 (which this EFS does) is rather arbitrary...and not recommended by the originator of the study (Han's or Al...depending on how long ago you started reading his works).

        Garth
        Garth

        Comment


        • #5
          PFE

          Can anyone tell me how to adjust the time periods and smoothing periods for the efs download below by Alex?

          Comment


          • #6
            jones24621
            You need to modify the study to be able to do that. To modify the study do the following.
            In the first lines of main add the following statement
            if(Length==null) Length = 10;
            Then to make this user defined parameter available in Edit Studies replace function main() with function main(Length)
            Then look for all the instances of the value 10 in the script and replace them with Length. Also replace 9 with Length-1 in all instances of Close[9]
            Once you have implemented these changes you will be able to select the length through Edit Studies (note that if the study is already loaded in the efs you need to Remove it first and then re-apply it to the chart for the changes to take effect)
            Alex

            Comment


            • #7
              Alexis, if I try to replace the code as you suggested I get syntax errors. Could you please post the new code again as a new *.efs file?

              Comment


              • #8
                Tekunda
                A better solution would be for you to post the efs as you have modified it so that I or someone else can look it over and guide you in correcting the errors. This way you would acquire a fuller understanding of the process.
                Alex

                Comment


                • #9
                  Here its is.
                  Attached Files

                  Comment


                  • #10
                    Tekunda
                    Open your efs with the Editor and run the Syntax Check and the first error it will show is the following
                    line 23: ReferenceError: length is not defined
                    In line 23 you define the default value used for Length so it should be a number such as for example 10 as suggested in my reply to jones24621. I suspect you had initially written this correctly but then when you performed a Find and Replace 10 with Length that it got overwritten too.
                    Once you fix the above error run a Syntax Check again and you will find another error in line 29. Remember that JavaScript is a case sensitive language.
                    Once you fix that error you will get no more errors if you run the Syntax Check. However once you load the efs in a chart you will get another error. Follow the guidance provided by Formula Output Window and correct the error shown. Again as you Reload the Formula Output Window it will signal another error. Repeat the process following what the Formula Output Window is indicating until you get no more errors.
                    FWIW in modifying the efs you have actually followed my instructions correctly and only mis-spelled the words or used the wrong case.
                    If for any reason the efs should still not work post it again and I will look it over
                    Alex

                    Comment


                    • #11
                      Alexis, I am sorry to let you know that I tried my best (probably not good enough) but I am still getting a whole bunch of syntax errors.
                      Is it not possible that you post a working *.efs file here for a case like me, who apparently has his share of problems adapting efs code?
                      Attached Files

                      Comment


                      • #12
                        Tekunda
                        In the efs you just posted add Length inside the brackets of function main() ie it should be function main(Length)
                        Also in line 29 replace
                        var Close = getValue("Close", 0, -10);
                        with
                        var Close = getValue("Close", 0, -Length);
                        I am not sure I understand why you did not use the same efs you posted earlier, anyhow once you make these changes to the efs you just posted the script will work
                        Alex

                        Comment


                        • #13
                          Alexis, thank you. I have indeed overlooked to put the Length in brackets. Since I got the syntax errors from the very beginning I was also not sure to replace the -10 with -Length.
                          Anyway it is working now prefectly.

                          Comment


                          • #14
                            Tekunda
                            You are most welcome. Glad to hear that you have the script working perfectly.
                            Alex

                            Comment

                            Working...
                            X