Inverse transform sampling: Difference between revisions

Content deleted Content added
Sowhates (talk | contribs)
Sowhates (talk | contribs)
Line 28:
For the [[normal distribution]], the lack of an analytical expression for the corresponding quantile function means that other methods (e.g. the [[Box–Muller transform]]) may be preferred computationally. It is often the case that, even for simple distributions, the inverse transform sampling method can be improved on:<ref>{{cite book |author=Luc Devroye |url=http://www.eirene.de/Devroye.pdf |title=Non-Uniform Random Variate Generation |publisher=Springer-Verlag |place=New York |year=1986}}</ref> see, for example, the [[ziggurat algorithm]] and [[rejection sampling]]. On the other hand, it is possible to approximate the quantile function of the normal distribution extremely accurately using moderate-degree polynomials, and in fact the method of doing this is fast enough that inversion sampling is now the default method for sampling from a normal distribution in the statistical package [[R (programming language)|R]].<ref>{{Cite web|url=https://stat.ethz.ch/R-manual/R-devel/library/base/html/Random.html|title = R: Random Number Generation}}</ref>
 
==Formal statement==
==Definition==
 
TheFor any [[probabilityrandom integral transformvariable]] states that if <math>X\in\mathbb R</math>, is a [[continuousthe random variable]] with [[cumulative distribution function]] <math>F_X^{-1}(U)</math>, thenhas the randomsame variablelaw as <math>Y=F_X(X)</math>, haswhere a<math>F_X^{-1}</math> is the [[uniformCumulative distribution function#Inverse_distribution_function_(continuousquantile_function)|uniformgeneralized distributioninverse]] on [0,&nbsp;1]. The inverse probability integral transform is justof the inverse[[cumulative of this: specifically, ifdistribution function]] <math>YF_X</math> has a uniform distribution on [0,&nbsp;1] and if of <math>X</math> has a cumulative distribution and <math>F_XU</math>, thenis theuniform random variableon <math>F_X^{-[0,1}(Y)]</math> has the same distribution as <math>X</math> .
 
For [[Random_variable#Continuous_random_variable|continuous random variables]], the inverse probability integral transform is indeed the inverse of the [[probability integral transform]], which states that for a [[continuous random variable]] <math>X</math> with [[cumulative distribution function]] <math>F_X</math>, the random variable <math>U=F_X(X)</math> is [[uniform distribution (continuous)|uniform]] on <math>[0,1]</math>.
 
[[File:InverseFunc.png|thumb|360px|Graph of the inversion technique from <math>x</math> to <math>F(x)</math>. On the bottom right we see the regular function and in the top left its inversion.]]