Total matched bets for 'back' versus 'lay'

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • lonestar79
    Junior Member
    • Sep 2015
    • 11

    #1

    Total matched bets for 'back' versus 'lay'

    Hi all,

    I am using the listMarketBook function of API to download the offered prices in the exchange for a game. This function shows the total matched amount for each selectionID; however it does not break down this matched amount as the total matched on the 'back' side of the market versus the 'lay' side. Is there a way to get this information please?
  • Merlin
    Junior Member
    • Jan 2009
    • 56

    #2
    Hi lonestar,

    The total is the total of 'back' stakes matched - if you need to find the total 'lay' value, you need to call listMarketBook with the priceData parameter of priceProjection set to EX_TRADED and do the multiplication yourself.

    cheers

    Merlin

    Comment

    • lonestar79
      Junior Member
      • Sep 2015
      • 11

      #3
      Thank you Merlin, that makes sense.

      Comment

      • lonestar79
        Junior Member
        • Sep 2015
        • 11

        #4
        Can I ask a follow up question on this please?

        For a particular market, I call listMarketBook many times a minute with priceData parameter of priceProjection set to EX_BEST_OFFERs. Hence I observe the change in the amount offered at the best back price over very short periods of time. I then observe the change in matched amount for the same back price (using EX_TRADED). The matched amount is exactly 2 times the change in the offered amount. Why would this be? I suspected that there is a bug in my code which results in double counting but so far I have not found any. Is there a reason why matched amount would be 2 times the change in offered amount?

        Comment

        • betdynamics
          Junior Member
          • Sep 2010
          • 534

          #5
          You are dealing with an Exchange, so matching a bet involves two transactions - one a back; the other a lay.

          If I place a £2.00 back bet at a given set of odds and the bet is matched, then it means that I have been matched against someone else who layed at those given odds.

          So, there is one matching back bet for £2.00 and one matching lay bet for £2.00 - hence why there is an increase of £4.00 in the total matched value.

          Comment

          • lonestar79.
            Junior Member
            • Jan 2016
            • 4

            #6
            Betdynamics,

            Thank you for the answer. Just for my clarity, can I check one detail: To my mind, the amount matched depends on the odds where the match happened. If you backed £2 at an odds of 3, then the other side to this match is risking £4 against you. So the amount matched on back side is £2 and lay side is £4, no?

            It seems that the tradedAmount field assumes that both sides are a £2 pound match though. (when listmarketbook function is used with price projection=EX_TRADED). This is the source of my confusion. I can live with the output being as it is but I just want to double check that I am not missing anything in my understanding above.

            Thank you for any help.

            Comment

            • betdynamics
              Junior Member
              • Sep 2010
              • 534

              #7
              I should have said £2.00 liability on the lay (rather than a £2.00 bet).

              You are matching like for like - so my £2.00 will be matched against someone else's £2.00 liability. It doesn't have to be the entirety of their bet, just £2.00 of their liability.

              Comment

              • lonestar79.
                Junior Member
                • Jan 2016
                • 4

                #8
                Understood. Thank you for answering.

                Comment

                • Nick JD
                  Junior Member
                  • Jan 2015
                  • 47

                  #9
                  Along these lines, I found this simple, short video great for explaining BF's cross-matching.

                  https://www.youtube.com/watch?v=Bys1lu-18wo

                  Comment

                  • lonestar79.
                    Junior Member
                    • Jan 2016
                    • 4

                    #10
                    Hi Betdynamics,

                    I just noticed that sometimes the change in the matched amount is not 2 times the change in amount offered at best back price, but rather equal to 1 times the change in amount offered. So I am back to being confused now... Any idea why this might be happening? Most of the time, the "2 times" rule seems to hold but every once in a while it doesn't.

                    Comment

                    • betdynamics
                      Junior Member
                      • Sep 2010
                      • 534

                      #11
                      Is the change always even?

                      If so, then it is always two times something, so the two times rule still stands.

                      It could be 2 x a cross-matched odds value, rather than the currently displayed odds value.

                      Comment

                      • lonestar79.
                        Junior Member
                        • Jan 2016
                        • 4

                        #12
                        Not always even unfortunately... How can I get a definitive answer on this? Is there some email contact of Betfair developers that I could try?

                        Comment

                        • Lopiner
                          Junior Member
                          • Feb 2009
                          • 117

                          #13
                          I have also noticed this, it would be very interesting to see this answered.
                          You can try bdp@betfair.com
                          fooledbyabet.com

                          Comment

                          • jptrader
                            Junior Member
                            • Nov 2009
                            • 82

                            #14
                            I have also noted this, and I am quite sure it happens after cross matching. E.g. if the lay side is matched, but not against a back bet on the same selection, but by a cross matching bet, the matched amount reported for that selection is only 1 times the matched amount. (Which makes sense as there was no back bet on that selection)

                            Comment

                            • Lopiner
                              Junior Member
                              • Feb 2009
                              • 117

                              #15
                              I also think that's the most probable scenario jptrader, it makes sense.
                              fooledbyabet.com

                              Comment

                              Working...
                              X