# Parametrization of a skew-normal distribution such that negative part is constant

I was wondering, how the parameters of the skew-normal distribution (https://en.wikipedia.org/wiki/Skew_normal_distribution) would be constrained when I require that a constant part of its support is in the negative range, i.e.,

$$\int_{-\infty}^0 p(x; \xi, \omega, \alpha)\, dx=a.$$

In other words, how can I determine which set of parameters would result in $$a=0.1$$?

There'll be a space of solutions; with 3 parameters you should end up with some 2D surface.

As it says at the Wikipedia page, the cdf of the skew normal is $$F(x;\alpha,\xi,\omega) =\Phi \left({\frac {x-\xi }{\omega }}\right)-2T\left({\frac {x-\xi }{\omega }},\alpha \right),$$ where $$T$$ is Owen's $$T$$-function. The $$T$$ function can be calculated pretty readily; there's references with algorithms and links to code.

I'm pretty sure this cdf is not going to have a closed form inverse, so you'll be using iterative methods to find roots of $$F(0;\theta)-\alpha=0$$, where $$\theta$$ is the vector of parameters. You may be lucky enough to find code that does the inverse cdf for the standard case, but I haven't seen one. If you do the problem is relatively simple. [Edit: It looks like both R and Python offer an inverse cdf function. In the case of R sn:::qsn; in the case of Python see scipy.stats, specifically skewnorm.ppf.]

Note that if there's a solution to $$\Phi(t)-2T(t;\alpha)=a$$ (i.e. the standard version of the distribution with $$\xi=0,\omega=1$$) then for any $$\omega>0$$, $$\xi=-\omega t$$ will be a solution to the original problem (because when $$z=0$$, $$\frac{z-\xi}{\omega}=t$$). Consequently, you can generate a 1-D space of solutions directly from solutions to the "standard" form of solving the inverse-cdf problem in $$t$$ given $$\alpha$$ -- i.e. finding solutions to $$F(t;\alpha)=a$$.

So the approach for some given $$a$$ would be to find the range of $$\alpha$$ values which have some $$t$$ for which $$F(t;\alpha)=a$$ is true, and for each desired $$\alpha$$ find the corresponding $$t$$ (this will be a curve relating $$t$$ to $$\alpha$$ for some set of values of $$\alpha$$, and then generate a set of $$\omega,\xi$$ values as above to solve the original problem you posed, yielding a 1-D linear subspace in $$\omega,\xi$$ for each $$\alpha$$ you want to consider (say over some grid within the possible range of $$\alpha$$ values.

There is no unique solution. I would suggest fixing the location and scale parameters and finding the skewness parameter numerically. This can be done in R as the skew normal distribution is implemented in the R package sn.

https://cran.r-project.org/web/packages/sn/index.html

For example, by fixing $$\xi=0, \omega = 1$$ we obtain,

library(sn)
# desired probability level
p0 <- 0.1
# instrumental function to find the skewness parameter
tempf <- Vectorize(function(alpha0) psn(0, xi = 0, omega = 1, alpha = alpha0) - p0)
# finding the root
root <- uniroot(tempf,c(-5,5))
# checking the probability
psn(0, xi = 0, omega = 1, alpha = root$root)  You can apply the same idea to other types of skew-normals, like the asymmetric normal or two-piece normal using the R package twopiece. https://r-forge.r-project.org/R/?group_id=2149 library(twopiece) # desired probability level p0 <- 0.1 # instrumental function to find the skewness parameter in (-1,1) tempf <- Vectorize(function(alpha0){ptp3(x = 0, mu = 0, par1 = 1, par2 = alpha0, param = "eps", FUN = pnorm) - p0} ) # finding the root root <- uniroot(tempf,c(-0.99,0.99)) # checking the probability ptp3(0, 0, 1, root$root, param = "eps", FUN = pnorm)