1. #1
    readerea
    readerea's Avatar Become A Pro!
    Join Date: 04-21-11
    Posts: 1

    excel and chi-square tests

    I know there are some smart people on this forum, so I hope someone can pass judgement on the following.
    I have a large Excel file of flat races from the UK and Ireland. I run a number of VBA macros to simulate a variety of betting/laying strategies and then test the results. My most common test is use the chi-squared distribution to test that the ratio of wins to selections (strike rate) from a particular strategy is better than one that would be obtained by selecting a bet/lay at random.
    I tried to use the Excel ChiTest function but couldn’t make it work from a VBA macro. Has anyone ever managed to make this function work from VBA?
    To get round this I have approached the chi-squared test from the following angle. I calculate the square of the difference between the observed results (ratio of successful outcomes to selections) and the expected random results (ratio of successful outcome from randomly selected runner to number of randomly selected runners). I divide this by the expected outcome and then call the Excel ChiDist function with that value and 2 degrees of freedom, in order to determine the probability that the strike rate from the strategy is the sane as the strike rate from a random selection strategy.
    I choose 2 degrees of freedom as I have 4 pieces of data – success from strategy, number of selections from strategy, success from random choice, number of random choices – that produce two statistics – strike rate from strategy and strike rate from random selection. That gives me 4- 2 , =2 degrees of freedom.
    Would someone care to critique that approach?
    Thanks in advance.

  2. #2
    yak merchant
    yak merchant's Avatar Become A Pro!
    Join Date: 11-04-10
    Posts: 109
    Betpoints: 6170

    Quote Originally Posted by readerea View Post
    I know there are some smart people on this forum, so I hope someone can pass judgement on the following.
    I have a large Excel file of flat races from the UK and Ireland. I run a number of VBA macros to simulate a variety of betting/laying strategies and then test the results. My most common test is use the chi-squared distribution to test that the ratio of wins to selections (strike rate) from a particular strategy is better than one that would be obtained by selecting a bet/lay at random.
    I tried to use the Excel ChiTest function but couldn’t make it work from a VBA macro. Has anyone ever managed to make this function work from VBA?
    To get round this I have approached the chi-squared test from the following angle. I calculate the square of the difference between the observed results (ratio of successful outcomes to selections) and the expected random results (ratio of successful outcome from randomly selected runner to number of randomly selected runners). I divide this by the expected outcome and then call the Excel ChiDist function with that value and 2 degrees of freedom, in order to determine the probability that the strike rate from the strategy is the sane as the strike rate from a random selection strategy.
    I choose 2 degrees of freedom as I have 4 pieces of data – success from strategy, number of selections from strategy, success from random choice, number of random choices – that produce two statistics – strike rate from strategy and strike rate from random selection. That gives me 4- 2 , =2 degrees of freedom.
    Would someone care to critique that approach?
    Thanks in advance.
    I'm not qualified to analyze your Chi Square tests, but even if completely correct, without taking into account odds, I think you are testing against a incomplete and valueless model. Unless of course, this isn't a handicapping exercise, and is just stat class homework.

    There is a good discussion on Chi-Square Tests and problems with testing "odds lines" over at paceadvantage right now. There are some super smart guys over there.

  3. #3
    Wrecktangle
    Wrecktangle's Avatar Become A Pro!
    Join Date: 03-01-09
    Posts: 1,524
    Betpoints: 3209

    yak, can you show the link? I haven't found it yet. Thanks.

  4. #4
    uva3021
    uva3021's Avatar Become A Pro!
    Join Date: 03-01-07
    Posts: 537
    Betpoints: 381

    WorksheetFunction.ChiTest(.....)

  5. #5
    yak merchant
    yak merchant's Avatar Become A Pro!
    Join Date: 11-04-10
    Posts: 109
    Betpoints: 6170

    Quote Originally Posted by Wrecktangle View Post
    yak, can you show the link? I haven't found it yet. Thanks.
    Sorry I conflated two threads in my mind.

    Here is the on one Chi Square, it kind of devolved but still worth a read.

    http://bit.ly/dK7jSB



    In this thread,

    http://bit.ly/gJ1qBN

    It starts as a different discussion, but the ideas of calibrating an odds line comes up. in post 48 read the link provided by GT. It is by far the best explanation of the problems with creating your own odds line.


    Cheers

  6. #6
    ManBearPig
    ManBearPig's Avatar Become A Pro!
    Join Date: 12-04-08
    Posts: 2,473

    Thanks for sharing those links Yak, I've been recently trying to find how ChiSqrTst could be of best use to me so hopefully this will help answer some of those questions. Thanks

  7. #7
    bztips
    bztips's Avatar Become A Pro!
    Join Date: 06-03-10
    Posts: 283

    You should check out this post by Ganchrow:

    http://www.sportsbookreview.com/forum/players-ta...r-success.html

Top