likelihood function for Tobit I am trying to sort out the likelihood function for a two-limit Tobit model (data censored from above and below). 
To start off, suppose you have data censored from below at zero. The log-likelihood of the one-limit Tobit model is
$$
\text{ln} L(\beta, \sigma) = \sum_{i=1}^n \left( 
    \underbrace{(1 - D_i)~ \text{ln}~ [ 1 - \Phi \frac{x_i \beta}{\sigma} ]}_{\text{Censored}}
     +
     \underbrace{D_i~ [\text{ln} ~\phi (\frac{y_i - x_i \beta}{\sigma}) - \text{ln}~ \sigma ]}_{\text{Uncensored}} \right)
$$
where $\Phi$ and $\phi$ are the Gaussian CDF and PDF, and $D_i = 0$ if $y_i = 0$. The first brace shows the likelihood contribution of a censored observation; the second shows the likelihood contribution of an uncensored observation. 
Now suppose the data are also censored from above at 20. How would $L(\beta, \sigma)$ be rewritten to capture this?
What I am thinking is $L(\beta, \sigma)$ should look like 
$$
\text{ln}  L(\beta, \sigma) = L_{\text{censored below}} + L_{\text{uncensored}} + L_{\text{censored above}}
$$
 A: Yes, you are exactly on the right track. The log-likelihood can be decomposed into the three parts pertaining to those observations $y_i$ that are left-censored, uncensored, and right-censored, respectively.


*

*For the uncensored observations, the likelihood contribution is simply the density $f(y_i)$.

*For the left-censored observations the contribution is the probability of falling below the censoring point, e.g., in the case of $0$ it is simply the cumulative distribution function $F(0)$.

*And in the case of right-censoring at 20, you get the probability to be above the censoring point, i.e., $1 - F(20)$.
Thus, more formally, we can write this for a normally distributed model in terms of the standard normal PDF $\phi(\cdot)$ and CDF $\Phi(\cdot)$, respectively, by applying the proper scaling.


*

*$f(y_i; x_i^\top\beta, \sigma) = \phi\left(\frac{y_i - x_i^\top\beta}{s}\right)/\sigma$

*$P(y_i \le 0) = F(0; x_i^\top\beta, \sigma)) = \Phi\left(\frac{0 - x_i^\top\beta}{\sigma}\right) = 1 - \Phi\left(\frac{x_i^\top\beta}{\sigma}\right)$

*$P(y_i > 20) = 1 - F(20; x_i^\top\beta, \sigma)) = 1 - \Phi\left(\frac{20 - x_i^\top\beta}{\sigma}\right)$
And then you need to take logs and sum them up across all observations (i.e., within each of the three groups and across the groups).
