In this course we will use the method of moments to estimate the parameters of any distributions that we fit. In Math235 you will learn about an alternative method called Maximum Likelihood Estimation.
In essence, a moment measures shape. For random variables this characterizes the shape of the probability distribution. For example, the first moment is the mean of the distribution. In general, the moment for a random variable, , is defined as:
Thus the first four moments are:
Just as the sample mean is an estimate of the population mean, the sample moments are estimates of the population moments. Thus the sample moment, for data is defined as:
The method of moments estimator of a set of parameters is defined as the solution to the set of equations:
i.e. the population moment equated to the sample moment.
Theoretically you could use any moment to estimate but typically we use the first moments where is dimensional. This amounts to solving a system of equations.
Let be a random sample from the probability density given by
Find the method of moments estimator for .
Answer. The distribution has one parameter so we use the first moment equation,
In order to solve this we first need to calculate the expectation,
Substituting this into the first moment equation gives,
The following paragraphs detail the derivations of the method of moments estimates for common distributions.
The Bernoulli distribution has one parameter, and mean . The method of moments estimate is thus:
i.e. the estimate of the probability of success is the average number of successes observed in the data. This is probably the estimate you would have thought to use anyway!
Penalty shoot-outs were introduced into World Cup finals in 1982. Since then 26 matches have been decided by penalties, see Table 2.2 for details. In total 240 penalties have been taken resulting in 170 goals. Calculate the method of moments estimate for the probability of a goal from a single shot, be careful to state your assumptions.
Answer. As the outcome of a penalty is goal or no goal, this is a binary response. The Bernoulli distribution seems appropriate to model this but we are making the following assumptions by using it:
the probability of a goal is the same for each shot taken;
whether or not a goal is scored at each penalty is independent of all the other penalties taken.
Answer. Assuming a Bernoulli distribution the method of moments estimate is number of successes/total number of tries, i.e. .
Are the assumptions you made in example 2.4.2 appropriate?
Answer. It is unlikely that the assumptions made are appropriate. This is because of several reasons, including:
one person could have taken multiple penalties (across years)
one person could be better or worse at taking penalties than another
the current ‘‘score’’ could impact on the probability of scoring (mental pressure).
Year | Teams | Scores | Aggregate |
---|---|---|---|
1982 | West Germany v France | 5/5-4/5 | 9/10 |
1986 | France v Brazil | 4/5-3/4 | 7/9 |
West Germany v Mexico | 4/4-1/3 | 5/7 | |
Belgium v Spain | 5/5-4/5 | 9/10 | |
1990 | Rep. of Ireland v Romania | 5/5-4/5 | 9/10 |
Argentina v Yugoslavia | 3/5-2/5 | 5/10 | |
Argentina v Italy | 4/5-3/5 | 7/10 | |
West Germany v England | 4/5-3/5 | 7/10 | |
1994 | Bulgaria v Mexico | 3/4-1/4 | 4/8 |
Sweden v Romania | 5/6-4/6 | 9/12 | |
Brazil v Italy | 3/5-2/5 | 5/10 | |
1998 | Argentina v England | 4/5-3/5 | 7/10 |
France v Italy | 4/5-3/5 | 7/10 | |
Brazil v Netherlands | 4/4-2/4 | 6/8 | |
2002 | Spain v Rep. of Ireland | 3/5-2/5 | 5/10 |
South Korea v Spain | 5/5-3/4 | 8/9 | |
2006 | Ukraine v Switzerland | 3/4-0/3 | 3/7 |
Germany v Argentina | 4/4-2/3 | 6/7 | |
Portugal v England | 3/5-1/4 | 4/9 | |
Italy v France | 5/5-3/5 | 8/10 | |
2010 | Paraguay v Japan | 5/5-3/4 | 8/9 |
Uruguay v Ghana | 4/5-2/4 | 6/9 | |
2014 | Brazil v Chile | 3/5-2/5 | 5/10 |
Costa Rica v Greece | 5/5-3/4 | 8/9 | |
Netherlands v Costa Rica | 4/4-3/5 | 7/9 | |
Netherlands v Argentina | 2/4-4/4 | 6/8 |
The Geometric distribution has one parameter, and mean . The method of moments estimate is thus:
As is the total number of successes and is the total number of attempts, this too is probably the estimate you would have thought to use.
The UK open data initiative publishes statistics on pass rates for driving tests: 2020https://www.gov.uk/government/collections/driving-tests-and-instructors-statistics . A bar plot of the data is in Figure LABEL:drivingtestpass. What distribution would you use to model this data? Calculate the method of moments estimate of its parameter(s).
R> data(driving1213)
R> tot.pass=colSums(driving1213[,c(3,6,9,12,15,18)])
R> barplot(tot.pass, names.arg=c(’1st’,"2nd","3rd","4th","5th","6th+"))
Answer. The data is for number of times until a person passes their driving test. Once passed you do not take the test again (unless your license is removed). This sounds like a Geometric distribution where trials continue until a positive outcome is seen. The method of moments estimate for a Geometric distribution is total number of successes divided by total number of attempts, thus for the driving data, this is approximately as we don’t know how many tests those taking 6+ actually took.
sum(tot.pass)/sum(tot.pass*1:6)
The Poisson distribution has one parameter, and mean . The method of moments estimate is thus:
the same as in the Bernoulli case.
The Uniform distribution has two parameters with mean and variance . The method of moments estimate is thus the solution of the simultaneous equations:
(2.1) | ||||
(2.2) |
Recall that so that Equation (2.2) can be written as
(2.3) |
Substituting in the definition of the population mean and rearranging Equation (2.1) we get,
Substituting this into Equation (2.3) and rearranging we get,
Substituting our estimate of back into our estimate for gives,
The Normal distribution has two parameters with mean and variance . The method of moments estimate is thus the solution of the simultaneous equations:
(2.4) | ||||
(2.5) |
Taking Equation (2.4) we have,
(2.6) |
Recall that so that Equation (2.5) can be written as
Now substituting in from Equation (2.6) gives
Whilst most of the formulae above are logical estimates of the parameters in question, it is crucial that you be able to derive and justify your use of them. Many of you may blindly believe that the sky is blue but how many of you can convince someone who insists that the sky is green using scientific and logical arguments? It is at this time in your mathematical career that you need to be making sure that you do not blindly believe and ask why. Sometimes you may not yet have the tools to understand the answer and thus may be told ‘‘you will find out in MathXXX’’ but you should be asking the questions.
Let be a random sample from the probability mass function given by
Find the method of moments estimator for .
Answer. There is one parameter so we use the first moment equation:
Firstly we need to calculate the expectation of the pmf:
Substituting this into the first moment equation we get:
TIP: General Approach to MoM questions
The general approach to answer these questions is:
1.
Decide on which distribution to use and what the parameters are.
2.
Write down the moment equations (remember: 1 equation per parameter you have to estimate)
3.
Calculate the moments using the distribution from (1).
4.
Plug-in the moments calculated in (3) into the moment equations from (2)
5.
Solve the moment equations for the parameters (might have to use simultaneous equations for
multi-parameter problems). This is the general estimator for the distribution of interest.
6.
Plug-in specific numbers for the scenario, if given in the question. This is the specific
parameter estimate for the data in question.
Now that we can fit parametric models to data, the following section discusses how to assess
whether a specific parametric model may be an appropriate approximation.