Announcement

Collapse
No announcement yet.

Advance Decline line

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Advance Decline line

    Can anyone help with code for an advance decline line (advancing issues - declining issues on the NYSE) that can be used intraday? Programming has never been my strong suit.....

    Thanks,

  • #2
    ptb
    For intraday you could use the symbol $ADD for Advance-Decline.
    If instead you would like to calculate the cumulative Advance-Decline Line on daily charts you may want to go to this thread as someone has already programmed an efs to do that.
    Alex

    Comment


    • #3
      $ADD

      Thanks Alexis - I hate to be stupid about thsis, but how do I add teh $ADD to an existing chart?

      Comment


      • #4
        ptb
        I assume that you want to see the $ADD in addition to the symbol you already have on a chart. In that case probably the simplest solution is to use the attached 'Symbol' efs which will plot a symbol as an indicator.
        The default is set for $INDU but you can go to Edit Studies and insert $ADD in the Sym box.
        If instead you want to have $ADD as the default then open the efs with Editor and change the symbol in Line 12 from $INDU to $ADD
        Alex
        Attached Files

        Comment


        • #5
          $ADD

          Alexis - thanks again! That works great.

          One more question - can I add code to have a moving average of the $ADD?

          I got pretty good at Tradestation Easy Language, but Java seem to go right over my head....

          Thanks again!

          Comment


          • #6
            ptb
            I think the attached does what you ask.
            To create it I just took the ma.efs that is in the Library subfolder of Formulas and added the Symbol option in Line 20.
            The default length for the MA is 10 and can be changed in Edit Studies. If you want to change the default setting use the Editor and change the value in Line 13.
            Hope this helps
            Alex
            Attached Files
            Last edited by ACM; 04-20-2003, 08:23 AM.

            Comment


            • #7
              $ADD

              Alexis - a very big thank you this time!

              You have saved me hours.....

              Comment


              • #8
                $ADD

                Alexis - I thought I could do this, but must be missing something -

                I woudl like to plot both the $ADD and the MA in the same pane. I tried combining the codes you sent me, but only get teh $ADD.

                Can you help me just once more???

                thanks,

                Comment


                • #9
                  ptb
                  In the mean time here is a quick solution.
                  Run both efs then click on one of the studies and while pressing the <Shift> key drag it on the other.
                  For more detailed instructions on how to merge studies go to this page. The explanations are available on top of each image.
                  Alex
                  Last edited by ACM; 04-20-2003, 11:40 AM.

                  Comment


                  • #10
                    ptb
                    And here is the efs that combines the two.
                    Alex
                    Attached Files

                    Comment


                    • #11
                      $add



                      THANK YOU, THANK YOU, THANK YOU!!!!

                      Comment


                      • #12
                        ptb
                        Attached is a slightly better version. You can now change the symbol in Edit Studies rather than having to use the Editor.
                        Alex
                        Attached Files

                        Comment


                        • #13
                          how can i make this produce a negitive ??

                          ( 1 ) is there a way that i can make this created an inverted number ??? ideally i would like to be able to use this yet have it 5 times repeated , lol yet what i want is simpley this to make a negative number . i can repeat it many time myself .
                          i use some indicators that are lows when the mkt is at a high. so
                          if there is a way ( which im sure is simple yet i dont know how to do it ) to make this produce a negitive instead of a positive .
                          meaning it inverts the chart ( the indicator )from an uptrend to a down trend and vice versa id appreciate it .

                          ( 2 ) also if there is a way to also create a spread with in it id finally have found what i have been looking for .
                          hence instead of $indu
                          can i put $indu-$oex ????
                          i know there is other ways yet it has to do with a formula im creating .
                          any help to question 1 for starters would be very much appreciated.
                          Last edited by fiboguy; 12-08-2004, 10:05 AM.

                          Comment


                          • #14
                            fiboguy
                            (1) Open the efs and replace lines 43 and 44 with the following and it will invert the plot (see image below)

                            var vMA = (vSum/nLength)* -1;
                            var vSym = getValue("Close",nSym)* -1;


                            (2)Through Edit Studies you can modify the symbol. Type the spread as the nSym value
                            Alex

                            Comment

                            Working...
                            X