Pages:
Actions
  • #1 by soylolo on 05 May 2017
  • I'm playing with "Greening up on multiple positions with a target profit" trigger, and i can't understeand this condition:
    "and Selection's Trigger Expression sel_id % 2 is equal to 0"

    I understeand this is the randomize function, but i can't see what it exactly does.
    It doesn't look for the 2nd number to be 0, and it doens't look for 0 in the entire id

    What does "% 2" mean?


    And as a side question
    On some races, it returns true for say 7 selections, so it doens't bet at all since this condition is false (max bets set at 5):
    "and Selection's Trigger Expression matching_number is between 1 and max_bet_num"

    How can i make it to, in that case, back the first 3 selections? So it activates the random lay trigger, with still 2 bets to make
  • #2 by MarkV on 06 May 2017
  • Hi
    Good question. It is modulus or remainder. The help file describes as:
    % modulus or remainder. For example, 5 % 4 = 1, 36 % 6=0, 23 % 7 = 2

    so the idea in the trigger is to randomise whether to back or lay the selection according to the remainder or modulus of selections ID (sel_id)

    the attached screenshot shows how it works
    there is a selections id. this number is divided by 2, and there is no remainder (it divides equally into 2) so it returns 0

    and selections trigger expression sel_id % 2 is equal to 0
    therefore this selection will have a back bet not a lay bet


     
  • #3 by soylolo on 10 May 2017
  • Thank you very much. I understand now how it works

Pages:
Actions