fxDreema

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

    How to add pips to a price level for both JPY and non-JPY prices?

    Questions & Answers
    3
    3
    1038
    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.
    • D
      drewinbrissie last edited by

      Hi all,

      I want to add 10 pips to a price level so that it will work for both JPY pairs (2 digits) and non-JPY pairs (4/5) digit prices. Can anyone suggest an easy way to do this without having to manually perform the calculation twice in different blocks?

      For example, to add 10 pips to a non-JPY pairs I can "Adjust" a price level in a Condition or Formula block with "+0.001". But this doesn't work for JPY pairs where the adjustment would need to be "+0.1"

      Thanks Drew

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

        Try +10pips. In this, the keyword "pips" is replaced with some function that will take the symbol (market) from above and after some calculations it will produce the value that means 10 pips for this pair. Better put "pips" right after the number, without empty space in between. This keyword is not part of MQL4/MQL5, it's something that I added long time ago.

        Also, if you use %, this will be converted to /%.

        pips and % work only in Adjust fields... but I'm not completely sure 😄

        1 Reply Last reply Reply Quote 0
        • M
          miro1360 last edited by

          you can use fxdreema function in adjust field:

          • PipValue(Symbol())
            or adjust with MQL4 function:
          • MarketInfo(Symbol(), MODE_POINT)) (but here you need know if you are quoted in 5 digits or 4 (3 or 2)) 🙂

          or MarketInfo(Symbol(), MODE_TICKSIZE) ... I am not sure now what will be better, you can try both 😄

          Between trading and gambling is a very small gap, be careful.

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

          Online Users

          L
          S
          A
          F

          10
          Online

          146.7k
          Users

          22.4k
          Topics

          122.6k
          Posts

          Powered by NodeBB Forums | Contributors