Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Algorithm Help - "Average of Highs"

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

    Algorithm Help - "Average of Highs"

    To any programmers out there -

    I'm trying to think of an algorithm that essentially takes an "average of highs." I'm not quite certain how to approach this.

    I'm working with an oscillator, and I'd like to know, on average, the high points (and, by corollary, the low points) that this oscillator has reached over a set amount of time, and even since the oscillator's instantiation.

    Any ideas how to approach this? All suggestions are welcome.

    #2
    Originally posted by cgeorgan View Post
    To any programmers out there -

    I'm trying to think of an algorithm that essentially takes an "average of highs." I'm not quite certain how to approach this.

    I'm working with an oscillator, and I'd like to know, on average, the high points (and, by corollary, the low points) that this oscillator has reached over a set amount of time, and even since the oscillator's instantiation.

    Any ideas how to approach this? All suggestions are welcome.
    How are you defining a "high point" on an oscillator ?

    Comment


      #3
      Originally posted by koganam View Post
      How are you defining a "high point" on an oscillator ?
      Exactly, I'm not even sure how to approach this.

      Comment


        #4
        Originally posted by cgeorgan View Post
        Exactly, I'm not even sure how to approach this.
        Perhaps the Swing indicator running on the Osc?

        Comment


          #5
          Originally posted by cgeorgan View Post
          Exactly, I'm not even sure how to approach this.
          Unfortunately that is the problem with computers. We can only code the thing if we have a precise definition.

          Comment


            #6
            Hi cgeorgam,

            Not sure what you are trying to do but perhaps the highs of your oscillator can be looked at as swing highs (using the same approach) - and the lows as swing lows). You can then create a custom data series of the highs and lows and apply an SMA or EMA,...etc to it. If you are running time charts then you might be able to to get the time span and calculate the average high(or low) over that time period. Hope this helps.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by CarlTrading, 03-31-2026, 09:41 PM
            1 response
            156 views
            1 like
            Last Post NinjaTrader_ChelseaB  
            Started by CarlTrading, 04-01-2026, 02:41 AM
            0 responses
            90 views
            1 like
            Last Post CarlTrading  
            Started by CaptainJack, 03-31-2026, 11:44 PM
            0 responses
            138 views
            2 likes
            Last Post CaptainJack  
            Started by CarlTrading, 03-30-2026, 11:51 AM
            0 responses
            130 views
            1 like
            Last Post CarlTrading  
            Started by CarlTrading, 03-30-2026, 11:48 AM
            0 responses
            107 views
            0 likes
            Last Post CarlTrading  
            Working...
            X