|Code Listing by Peter Cotton|
The basic Harville method for estimating place, show, quinella, exacta and trifecta probabilities from win probabilities. Used and abused by bookmakers and punters the world over.
There are many valid critiques of this formula. Most recently "Explaining the Favorite-Longshot Bias: Is it Risk-Love or
Misperceptions" by Erik Snowberg and Justin Wolfers. See also
"discounted harville formula" (google).
Functor is an annotated function (i.e. a function_handle with named input and output arguments). Collections of functors can be automatically composed into new functors, using functor.compose and/or functor.combine
I sometimes find...
Y = BERNPDF(P) where P is an N x 1 vector returns the distribution of the sum of N Bernoulli random variables. Y is of length N+1 and Y(j) is equal to the probability that the sum adds to j+1. The vector P comprises the means of Bernoulli random...
A collection of one or more related @datasets, achieving a sparse (and possibly normalized) representation of a larger @dataset
Dataviews are compressed by providing a list of "key" variable names (analogous to key fields in...
Creates a 1,2 or 3 dimensional probability distribution supported on user-supplied lattice points subject to linear and moment constraints. A trite financial example is provided.
INTENT creates a plot of relationships between mfiles in the current directory, as inferred by the names of input and output arguments.
Little more than syntactic sugar for nchoosek, this small but surprisingly controversial function returns the number of (ordered) n-tuples of non-negative integers adding up to k, and if supplied a second argument, a listing of them. As an...