Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #12964
| From | Ray Koopman <koopman@sfu.ca> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: Modeling of NFL game results |
| Date | 2012-12-28 10:32 +0000 |
| Message-ID | <kbjsfn$mvn$1@smc.vnet.net> (permalink) |
| References | <kbbitr$9oc$1@smc.vnet.net> <kbh6da$iie$1@smc.vnet.net> |
| Organization | Time-Warner Telecom |
On Dec 27, 2:03 am, Scott Hemphill <hemph...@hemphills.net> wrote:
> Scott Hemphill <hemph...@hemphills.net> writes:
>
> [snip]
>
>> I decided to rate each team with a single number, such that the
>> probability that a team rated "r1" has a probability beating a team
>> rated "r2" is given by:
>>
>> p = CDF[NormalDistribution[], r1-r2];
>
> Hmmm. I guess my code actually implements "r2-r1" instead of "r1-r2".
> It doesn't matter, except one way high ratings are better than low
> ratings, and the other is vice versa.
>
>> filename="matrix.m";
>> prec;
>
> I don't know how this line got shortened. My original has "prec".
>
> Scott
> --
> Scott Hemphill hemph...@alumni.caltech.edu
> "This isn't flying. This is falling, with style." -- Buzz Lightyear
Some suggestions. Keep a 32 x 32 data matrix in which
data[[m,n]] = the # of times m beat n, m,n = 1...32.
The diagonals don't matter. The easiest way to eliminate infinite
solutions is to initialize it as data = Table[eps,{32},{32}],
where eps is some small positive value. (Use reals.)
Update every week:
win[m_,n_] := data[[m,n]]++;
tie[m_,n_] := (data[[m,n]] += .5; data[[n,m]] += .5);
Maximize Tr[LL[x,#]&/@Subsets[Range@32,{2}]].
Fix x[32] = 0, maximize with respect to x[1]...x[31].
Or define x[32] := -Tr[x/@Range@31], to fix the mean at 0.
If[logit === True,
LL[x_,{m_,n_}] := -(data[[m,n]]*Log[1. + Exp[x@n - x@m]] +
data[[n,m]]*Log[1. + Exp[x@m -
x@n]])
LL[x_,{m_,n_}] := data[[m,n]]*Log[.5 + .5*Erf[.42(x@m - x@n)]] +
data[[n,m]]*Log[.5 + .5*Erf[.42(x@n - x@m)]] ]
The .42 puts the two solutions on approximately the same scale
for .10 < p < .90 .
Caveat user: I haven't tried any of that.
Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Modeling of NFL game results Scott Hemphill <hemphill@hemphills.net> - 2012-12-25 07:00 +0000
Re: Modeling of NFL game results Ray Koopman <koopman@sfu.ca> - 2012-12-27 10:02 +0000
Re: Modeling of NFL game results Scott Hemphill <hemphill@hemphills.net> - 2012-12-28 10:32 +0000
Re: Modeling of NFL game results Ray Koopman <koopman@sfu.ca> - 2012-12-27 10:02 +0000
Re: Modeling of NFL game results Scott Hemphill <hemphill@hemphills.net> - 2012-12-27 10:03 +0000
Re: Modeling of NFL game results Ray Koopman <koopman@sfu.ca> - 2012-12-28 10:32 +0000
Re: Modeling of NFL game results Scott Hemphill <hemphill@hemphills.net> - 2012-12-28 10:32 +0000
Re: Modeling of NFL game results Scott Hemphill <hemphill@hemphills.net> - 2012-12-29 20:08 +0000
csiph-web