Maximum likelihood of Normal density under selection Consider the density function given by
$$
\left[\dfrac{\gamma_{\leq0} \mathbb{1}(t \leq 0) + \gamma_{>0} \mathbb{1}(t > 0)}{\gamma_{\leq0}\Phi\left(- \mu / \sigma\right) + \gamma_{>0}\Phi\left(\mu / \sigma\right)}\right] \phi\left(\dfrac{t - \mu}{\sigma}\right).
$$
The parameters $\gamma_{\leq 0}$ and $\gamma_{>0}$ denote the respective probabilities of observing a value of $t \in \mathbb{R}$ if it is nonpositive and positive. In addition, $\Phi(\cdot)$ denotes the standard Normal CDF and $\phi(\cdot)$ the standard Normal pdf. The function $\mathbb{1}(\cdot)$ is the indicator function.
Suppose that the values of the parameters $\gamma_{\leq 0}$, $\gamma_{>0}$ and $\sigma$ are all known. Given a value of $t$, what is the value of $\mu$ that assigns the greatest density to $t$? I.e., what is the MLE of $\mu$?
If the density function were simply $\phi\left(\dfrac{t - \mu}{\sigma}\right)$, then the MLE of $\mu$ would be whichever value is equal to the observed $t$. But I'm not sure how to derive the MLE with the additional factor of $\left[\dfrac{\gamma_{\leq0} \mathbb{1}(t \leq 0) + \gamma_{>0} \mathbb{1}(t > 0)}{\gamma_{\leq0}\Phi\left(- \mu / \sigma\right) + \gamma_{>0}\Phi\left(\mu / \sigma\right)}\right]$. Thanks so much for any help.
 A: To simplify the analysis, I will first deal with the special case where $\sigma=1$.  Your likelihood function here can be written by removing the proportionality constants, which gives:
$$\begin{align}
L_t(\mu)
&= \frac{\exp(-\tfrac{1}{2}(t-\mu)^2)}{\gamma_{\leq0} \Phi(-\mu) + \gamma_{>0} \Phi(\mu)}. \\[6pt]
\end{align}$$
Differentiating and applying the quotient rule gives:
$$\begin{align}
\frac{dL_t}{d\mu}(\mu)
&= \frac{\exp(-\tfrac{1}{2}(t-\mu)^2)}{[\gamma_{\leq0} \Phi(-\mu) + \gamma_{>0} \Phi(\mu)]^2} \begin{bmatrix}
(t-\mu) [\gamma_{\leq0} \Phi(-\mu) + \gamma_{>0} \Phi(\mu)] \\ - \phi(\mu) [-\gamma_{\leq0} \Phi(-\mu) + \gamma_{>0} \Phi(\mu)]
\end{bmatrix} \\[6pt]
&= \frac{\exp(-\tfrac{1}{2}(t-\mu)^2)}{[\gamma_{\leq0} \Phi(-\mu) + \gamma_{>0} \Phi(\mu)]^2} \begin{bmatrix}
\quad \ \ (t-\mu+\phi(\mu)) \gamma_{\leq0} \Phi(-\mu) \\ + (t-\mu-\phi(\mu)) \gamma_{>0} \Phi(\mu) \end{bmatrix} \\[6pt]
&= L_t(\mu) \times \frac{(t-\mu+\phi(\mu)) \gamma_{\leq0} \Phi(-\mu) + (t-\mu-\phi(\mu)) \gamma_{>0} \Phi(\mu)}{\gamma_{\leq0} \Phi(-\mu) + \gamma_{>0} \Phi(\mu)]}, \\[6pt]
\end{align}$$
which yields the score function:
$$s(\mu) = \frac{(t-\mu+\phi(\mu)) \gamma_{\leq0} \Phi(-\mu) + (t-\mu-\phi(\mu)) \gamma_{>0} \Phi(\mu)}{\gamma_{\leq0} \Phi(-\mu) + \gamma_{>0} \Phi(\mu)}.$$
(I will leave it as an exercise for you to check concavity or quasi-concavity of the log-likelihood function.)  Critical points of the likelihood function occur when the score is zero, giving the critical point equation:
$$(t-\hat{\mu}+\phi(\hat{\mu})) \gamma_{\leq0} \Phi(-\hat{\mu}) + (t-\hat{\mu}-\phi(\hat{\mu})) \gamma_{>0} \Phi(\hat{\mu}) = 0.$$
You would need to solve this equation using numerical methods (e.g., Newton-Raphson) which would give you the critical points of the likelihood function, yielding the MLE for $\mu$.
