Pages:
Actions
  • #1 by yorkiemac08 on 25 Jun 2013
  • Hi all how do i have an unequal green up and a stop loss for 1 whole point so i back at 6 and if it drifts to 7 stop loss fires and the same when it comes into 5 unequal green up fires i dont know how to get round the tick increments as  backing at 6 to greenup at 5 is 10 ticks but if it drifts to 7 its only 5 ticks. Regards Andrew
  • #2 by MarkV on 26 Jun 2013
  • Hi
    I have been playing around with this a bit, but I do not have a definite answer. There must be a way though, using b_tick and l_tick.

    Here is what I tried:

    r_ticks(back_price,1/b_tick)

    the idea being you work out how many ticks for one full point
    and then use r_ticks for that amount of ticks

    the problem, as you say, comes when the calculation spans across a tick increment change.

    For prices in the range 2.02 to 30.00 you can just add or subtract the number:

    back_price +1
    lay_price - 1
    etc.

    or you can set a constant
    back_price + [constant]
    etc.

    ...but you will need to round the result to the next tick increment

    If you actually want the prices as whole numbers:
    INTEGER(back_price+1)
    etc.

    Outside of the range 2.02 to 30.00 you will get invalid tick increments above 30.00 and 2.00 or below will equal 0, unless you adjust you calculation accordingly.

    Sorry I can't be more helpful. This probably just confirms what you have said already.
  • #3 by yorkiemac08 on 26 Jun 2013
  • Hi Mark thanks
Pages:
Actions