fxDreema

    • Register
    • Login
    • Search
    • Back to the main page
    • Categories
    • Recent
    • Tags
    • Popular
    • Search

    PAST MOVING AVERAGE DEFINITION

    Questions & Answers
    2
    11
    2114
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • G
      ggrobot last edited by

      Hi to all,
      I need to compare the the previous 5th candle close(candle-5) to the moving average that was there 5 periods before but i cannot define that spot, if i shift the MA -5 it will be wrong , if i let it there is no trade as the system tries to compare the canlde -5 with the price of MA now . how is it possible to define the closure of MA 5 periods behind???

      1 Reply Last reply Reply Quote 0
      • G
        ggrobot last edited by

        it would be nice if there was a box in every moving averge like the candle box where you choose which candle you need from the past. is there any great programmer that knows how to do it? 🙂

        1 Reply Last reply Reply Quote 0
        • roar
          roar last edited by roar

          How is shifting the ma wrong?

          Do you mean you want to compare candle (id5) to MA (id5) ?

          Need small help? Tag me in your post
          Need big help? https://www.fiverr.com/big_algo/automate-your-winning-strategy-in-mql4-or-mql5

          1 Reply Last reply Reply Quote 0
          • G
            ggrobot last edited by ggrobot

            i would like to compare candle close (0,the last candle) , with the price that MA or bollinger had5 periods ago. when you shift it the price MA had 5 periods ago with the shifting 5 MA is not the same.
            i dont know how to define the price any indicator had 5 periods ago.

            1 Reply Last reply Reply Quote 0
            • roar
              roar last edited by

              when editing the condition block, hit "more settings" and there you can adjust the ID.

              But working with shift is literally the same as working with candle id:
              MA shifted 2 = MA (id2)

              Need small help? Tag me in your post
              Need big help? https://www.fiverr.com/big_algo/automate-your-winning-strategy-in-mql4-or-mql5

              1 Reply Last reply Reply Quote 0
              • G
                ggrobot last edited by

                0_1501089089333_MASHIFT-15.JPG

                look at the example, , the green MA20 is shifted -15, while the red is the regular MA20. As you can see the prices are the same. i need to compare the candle id=0 last candle, with the price of the regular MA20(12310). In candles is easy because id takes you to that period, but here how we can get the price of the red MA20 15 periods before???

                roar 1 Reply Last reply Reply Quote 0
                • roar
                  roar @ggrobot last edited by roar

                  @ggrobot said in PAST MOVING AVERAGE DEFINITION:

                  0_1501089089333_MASHIFT-15.JPG

                  look at the example, , the green MA20 is shifted -15

                  Remove the - (minus) symbol 😄 +15

                  Also, you can use the ID method with indicators too, just like candles.

                  Need small help? Tag me in your post
                  Need big help? https://www.fiverr.com/big_algo/automate-your-winning-strategy-in-mql4-or-mql5

                  1 Reply Last reply Reply Quote 0
                  • G
                    ggrobot last edited by

                    0_1501090593029_MASHIFT15.JPG
                    I did but still i dont have the price12310 of the MA20 red 15 periods before 😞 which i want to compare

                    1 Reply Last reply Reply Quote 0
                    • roar
                      roar last edited by roar

                      Yes you do. At the latest candle you can now see where MA was 15 candles ago.
                      So, condition: candle (id 0) > ma shift 15 (id 0)
                      you get the same result with this condition: candle (id0) > ma (id 15)

                      Need small help? Tag me in your post
                      Need big help? https://www.fiverr.com/big_algo/automate-your-winning-strategy-in-mql4-or-mql5

                      1 Reply Last reply Reply Quote 0
                      • G
                        ggrobot last edited by

                        so this is applied to any MA or indicator, as long as i put in more settings id 15. In the more settings under MA in the id box the candle is referred. if you see it , it doesnt say MA id but candle id. is this correct??

                        1 Reply Last reply Reply Quote 0
                        • roar
                          roar last edited by

                          indicators are just calculations based on some candles. you see, everything starts from the price.
                          so you can think candle id is actually same as indicator id

                          Need small help? Tag me in your post
                          Need big help? https://www.fiverr.com/big_algo/automate-your-winning-strategy-in-mql4-or-mql5

                          1 Reply Last reply Reply Quote 0
                          • 1 / 1
                          • First post
                            Last post

                          Online Users

                          M
                          D
                          A
                          M

                          18
                          Online

                          146.7k
                          Users

                          22.4k
                          Topics

                          122.6k
                          Posts

                          Powered by NodeBB Forums | Contributors