Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Buy 5 ticks above the cross over of an indicator

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

    Buy 5 ticks above the cross over of an indicator

    Hello

    I want to buy 5 ticks above the indicator upper... would this setting in strategy builder be correct?
    see attached

    #2
    i have the settings on price change and not close.

    Comment


      #3
      Hello babouin77,

      Yes that looks correct, the offset is where you can do math to calculate a new price.

      Are you having a problem when testing it?

      I look forward to being of further assistance.

      Comment


        #4
        yes it is not opening the trade 5 ticks above the indicator? the reason I want it that way is i want to open a trade when a price cross above it and close when it cross below it but i am trying to find a way to not have it close and open when the price is fluctuating ... any help is appreciated

        Comment


          #5
          Hello babouin77,

          Did you see the print that you have in the condition in the output window? From the given details I don't see what the problem is, if the condition did not happen that would explain why the order was not placed, you could confirm that by seeing if the print was or was not printed.

          How are you otherwise comparing the crossing condition? , did the strategy use the "plot on chart" option for the indicators it used?

          The bool would be the suggestion if you want to do an action once when using OnPriceChange or OnEachTIck. Again if the condition is not becoming true that would be an area to check, you could check the bool is the correct value to allow the condition for the first time this happens.

          If you are unable to see the problem could you attach the strategy so I can view what you have made so far?

          I look forward to being of further assistance.

          Comment


            #6
            how can i share the strategy builder code?

            Comment


              #7
              Hello babouin77,



              You can find steps on the above page.

              Comment


                #8
                im sorry use this one thank you
                Attached Files

                Comment


                  #9
                  Hello babouin77,

                  Are you seeing historical trades placed at all or do you see nothing at all happening? I tried the script and this seems to be working historically and worked while using the simulated data feed going forward in time.

                  Can you provide some details about the chart settings you used for the test?

                  I look forward to being of further assistance.

                  Comment


                    #10
                    sure... so to be able to see the calculate on price action it is either i need to be trading live or on playback so i did a playback now and waited for a signal to come. as you can see in the image attached which happened on the /es 10 min candles the upper band is at 3203.99 technically the strategy will open when price cross above but I want it to buy when price is above by 5 ticks... and sell when price is below by 5 ticks. as you can see it bought just 1 cent above at 3204 and sold at 3203.75 (below the band. technically I do not want it to buy unless price reaches 3205.25 (5 ticks) above the bands. hope I am making sense and this can be achieved. thank you
                    Attached Files

                    Comment


                      #11
                      were you able to see my reply?

                      Comment


                        #12
                        Hello babouin77,

                        After looking at the script I see that your original image does not match what you have in the script now. Originally you had Ticks selected which is correct, in this strategy you have arithmetic selected and also have entered 1. If you want to do an offset of 5 ticks you need to select Ticks and then enter 5 in your condition in set 1.

                        Another item which I had not seen here is how the builder generates the offset in this condition. In this use case we actually need to use the numeric value wrapper to allow the offset to be calculated, the crossabove is cutting that part of the logic off. I have attached the script with that modification, to explain this you need to add on the right side of your condition Misc -> Numeric Value and then select the indicator from there.

                        I look forward to being of further assistance.
                        Attached Files

                        Comment


                          #13
                          ok thanks let me see how this will work

                          Comment


                            #14
                            if I want to do the opposite for short trade should I use lower than the lower band by 5 ticks or - 5 ticks?

                            Comment


                              #15
                              Hello babouin77,

                              Yes in that case you could do -5 to add negative 5 ticks which will subtract it.

                              I look forward to being of further assistance.

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by NullPointStrategies, Yesterday, 05:17 AM
                              0 responses
                              59 views
                              0 likes
                              Last Post NullPointStrategies  
                              Started by argusthome, 03-08-2026, 10:06 AM
                              0 responses
                              134 views
                              0 likes
                              Last Post argusthome  
                              Started by NabilKhattabi, 03-06-2026, 11:18 AM
                              0 responses
                              74 views
                              0 likes
                              Last Post NabilKhattabi  
                              Started by Deep42, 03-06-2026, 12:28 AM
                              0 responses
                              45 views
                              0 likes
                              Last Post Deep42
                              by Deep42
                               
                              Started by TheRealMorford, 03-05-2026, 06:15 PM
                              0 responses
                              50 views
                              0 likes
                              Last Post TheRealMorford  
                              Working...
                              X