Maximum likelihood for counting the number of cabs

174 Views Asked by At

Assume there are $N$ cabs driving through your city, each cab having a number between $1$ and $N$. You want to make a guess for $N$, so you write down the numbers of all the cab that you see. Let $x_1 < ... < x_k$ be those numbers.

I know that the best guess for $N$ is given by $x_k$ and it makes sense to me. But I simply don't understand the formal solution for it, even though I used several different resources. The argument is always as follows:

Defining the Likelihood-function

$$L_w(N) = \frac{1}{{N \choose k}},$$

one sees $L_w$ is falling monotonously in $N$, so one should choose $x_k = \max\{x_1,...,x_k\}$ as an estimator for $N$.

But this doesn't sound right to me. The goal is to maximize $L_w$, but when we know that $L_w$ is falling monotonously in $N$, why would we choose $x_k$ as an estimator then? The likelihood-function can't have its maximum in $N = x_k$.

1

There are 1 best solutions below

0
On BEST ANSWER

I think that you are missing the fact that the Likelihood function: $$L_w(N) = \frac{1}{{N \choose k}}$$ Has this form only for $N \ge x_k$. For $N<x_k$ it has the form: $$L_w(N) = 0$$ Because if $N<x_k$ it is impossible to obtain a sample $x_1,\dots,x_k$ because it is impossible to obtain $x_k$. So altogether our likelihood function is: $$L_w(N) = \begin{cases} 0 & \textrm{for } N < x_k \\ \frac{1}{{N \choose k}} & \textrm{for } N \ge x_k \end{cases}$$ And we see that the Likelihood function is decreasing but only for $N \ge x_k$ and before that it is $0$ so the maximum is attained exactly at $N=x_k$.