Presentation is loading. Please wait.

Presentation is loading. Please wait.

Maximum likelihood estimation

Similar presentations


Presentation on theme: "Maximum likelihood estimation"β€” Presentation transcript:

1 Maximum likelihood estimation
Michail Tsagris & Ioannis Tsamardinos

2 Histograms revisited Looks symmetric and unimodal.

3 Normal distribution 𝑓 π‘₯ = 1 2πœ‹ 𝜎 2 𝑒 βˆ’ π‘₯βˆ’πœ‡ 𝜎 2

4 MLE of normal distribution
Suppose we have collected some data, RNA expression measurements for example. We do a histogram and we see a nice bell shaped distribution. How do we find the parameters μ and 𝜎 2 ; Given, what we see, we will calculate the most probable values assuming that the sample comes from a normally distributed population. We need to estimate the values of these parameters which are most likely to have produced those data. The values which maximise the likelihoods of observing such data.

5 MLE of normal distribution
So we will calculate the values that maximise the likelihood of having observed these data. Denote the n values we have observed by π‘₯ 1 , π‘₯ 2 , …, π‘₯ 𝑛 . Each of these π‘₯ 𝑖𝑠 come from a normal population with some mean ΞΌ and some variance Οƒ2. The two values are the same and in addition, the values are independent from each other (independent and identically distributed, iid).

6 MLE of normal distribution
So, each π‘₯ 𝑖 can be plugged into the formula (probability density function) of the normal distribution: f (π‘₯ 𝑖 )= 1 2πœ‹ 𝜎 2 𝑒 βˆ’ π‘₯ 𝑖 βˆ’πœ‡ 𝜎 2 . Let us take the product of all the 𝑓 𝑖𝑠 : 𝐿(πœ‡, 𝜎 2 )= 𝑖=1 𝑛 πœ‹ 𝜎 2 𝑒 βˆ’ π‘₯ 𝑖 βˆ’πœ‡ 𝜎 The goal is to maximise the above expression. Better to maximise its logarithm. The two points (πœ‡, 𝜎 2 ) which maximise the L will maximise the log(L) as well.

7 MLE of normal distribution
β„“(πœ‡, 𝜎 2 )=βˆ’ 𝑛 2 log 2πœ‹ 𝜎 2 βˆ’ 𝑖=1 𝑛 π‘₯ 𝑖 βˆ’πœ‡ 𝜎 2 πœ•β„“ πœ•πœ‡ = 𝑖=1 𝑛 π‘₯ 𝑖 βˆ’πœ‡ 2𝜎 2 =0 β‡’ πœ‡ = 𝑖=1 𝑛 π‘₯ 𝑖 𝑛 = π‘₯ πœ•β„“ πœ• 𝜎 2 =βˆ’ 𝑛 2 𝜎 𝑖=1 𝑛 π‘₯ 𝑖 βˆ’πœ‡ 𝜎 4 =0β‡’ 𝜎 2 = 𝑖=1 𝑛 π‘₯ 𝑖 βˆ’πœ‡ 2 𝑛 .

8 MLE of mean, median and proportion
So, the MLE of the mean is simply the sample mean of the data. The sample median serves as the MLE of the median. What about proportions? Suppose that a dose of 1ΞΌL kills 5 of the 30 mice in a wet lab experiment. The estimated rate of killing of the dose of this specific drug is 5/30 = or 16.67%.

9 MLE of mean and median The sample mean can also be seen as the quantity ΞΈ that minimises the sum of squares of differences 𝑖=1 𝑛 π‘₯ 𝑖 βˆ’πœƒ 2 . The sample median on the other hand is the quantity ΞΈ that minimises the sum of absolute differences 𝑖=1 𝑛 π‘₯ 𝑖 βˆ’πœƒ .

10 Confidence intervals Suppose one calculates the proportion of mice killed at a given drug dose. Is it enough to present just a number? What else can he say? The uncertainty must be quantified via a range of most likely values, an interval of most likely values, an interval of high confidence. The most common sentence is 95% confidence interval. The 5% is the standard, the most popular, but not the unique number.

11 Confidence intervals We performed a study, found some summary statistics and constructed a 95% confidence interval for the mean or the proportion. This means that with 95% probability the true means lies within the computed range.

12 Confidence intervals We performed a study, found some summary statistics and constructed a 95% confidence interval for the mean or the proportion. This means that with 95% probability the true means lies within the computed range. Wrong!!!

13 Confidence intervals We performed a study, found some summary statistics and constructed a 95% confidence interval for the mean or the proportion. But we only did the analysis once. In other words, our confidence interval has a 95% probability (we expect it is one of the 95% intervals) to have included the true mean or proportion or any parameter in general.

14 Confidence intervals We performed a study, found some summary statistics and constructed a 95% confidence interval for the mean or the proportion. If we were to repeat this analysis many times, we would expect that 95% of the times we would have included the true mean. Correct!!!

15 Confidence intervals

16 Confidence intervals

17 Confidence intervals

18 (Student’s) t distribution (William Gosset)
We have spoken of the normal distribution. Let us now see the t distribution. 𝑓 π‘₯;πœ‡, 𝜎 2 = 1 2πœ‹ 𝜎 2 𝑒 βˆ’ π‘₯βˆ’πœ‡ 𝜎 Normal density 𝑓 π‘₯;𝑣 = Ξ“( 𝑣+1 2 ) π‘£πœ‹ Ξ“( 𝑣 2 ) π‘₯ 2 𝑣 βˆ’ 𝑣 t density

19 (Student’s) t distribution (William Gosset)
As v (degrees of freedom) increases the distribution approaches the normal distribution. lim π‘£β†’βˆž 𝑑 𝑣 βˆ’>𝑁(0, 1)

20 Population and sample revisit
Greek letters indicate population parameters English letters correspond to sample estimates. Mean, variance and standard deviation example. πœ‡, 𝜎 2 , 𝜎. π‘₯, 𝑠 2 , 𝑠.

21 (1-Ξ±)% confidence interval for the mean
Suppose we have estimated the average glucose concentration to be π‘₯ =86Β mg/dL with a variance equal to 𝑠 2 =25 and we want to construct a 95% confidence interval for the true concentration. Our sample consists of 𝑛=31 people. 95% is called confidence level

22 (1-Ξ±)% confidence interval for the mean
Suppose we have estimated the average glucose concentration to be π‘₯ =86Β mg/dL with a variance equal to 𝑠 2 =25 and we want to construct a 95% confidence interval for the true concentration. Our sample consists of 𝑛=31 people. π‘₯ βˆ’ 𝑑 1βˆ’ π‘Ž 2 , π‘›βˆ’1 𝑠 𝑛 , π‘₯ + 𝑑 1βˆ’ π‘Ž 2 , π‘›βˆ’1 𝑠 𝑛 . We have everything but the term 𝑑 1βˆ’ π‘Ž 2 , π‘£βˆ’1 .

23 t distribution tables

24 (1-Ξ±)% confidence interval for the mean
𝑑 1βˆ’ π‘Ž 2 , π‘£βˆ’1 = 𝑑 1βˆ’ , 35βˆ’1 = 𝑑 0.975, =2.042 86 βˆ’ , = 84.166,

25 (1-Ξ±)% confidence interval for the proportion
In sample of 132 women who smoke, 58 of them were found to have increased chances of getting breast cancer. 𝑝 = = or 43.94% The relevant 95% confidence interval is given by 𝑝 βˆ’ Ξ– 1βˆ’ π‘Ž 2 𝑝 (1βˆ’ 𝑝 ) 𝑛 , 𝑝 + Ξ– 1βˆ’ π‘Ž 2 𝑝 (1βˆ’ 𝑝 ) 𝑛 . What is Ξ– 1βˆ’ π‘Ž 2 ?

26

27 (1-Ξ±)% confidence interval for the proportion
Ξ– 1βˆ’ π‘Ž 2 = Ξ– 1βˆ’ = Ξ– =1.96. βˆ’ βˆ’ , (1βˆ’0.4394) βˆ’ βˆ’ , (1βˆ’0.4394) 132 0.3547, or %, 52.41% .


Download ppt "Maximum likelihood estimation"

Similar presentations


Ads by Google