Inverse transform sampling: Difference between revisions

Content deleted Content added
MarkSweep (talk | contribs)
correctness lemma from Devroye's book
MarkSweep (talk | contribs)
fmt
Line 1:
The '''inverse transform sampling method''' is a method of sampling a number at random from any [[probability distribution]] given its [[cumulative distribution function]] (cdf).
random from any [[probability distribution]], given its [[cumulative distribution function]] (cdf).
 
==The method==
Line 6 ⟶ 5:
The problem that the inverse transform sampling method solves is as follows:
 
*Let ''X'' be a [[random variable]] whose distribution can be described by the cdf d(''xF'').
*We want to generate values of ''xX'' which are distributed according to this distribution.
 
Many [[programming language]]s have the ability to generate [[pseudorandom number sequence|pseudo-random numbers]] which are effectively distributed according to the standard [[uniform distribution]]. If a random variable has that distribution, then the probability of its falling within any subinterval (''a'', ''b'') of the interval from 0 to 1 is just the length ''b'' -− ''a'' of that subinterval.
 
The inverse transform sampling method works as follows:
#Generate a random number from the standard uniform distribution; call this ''u''.
#Compute the value for ''x'' whichsuch hasthat the<math>F(x) associated= cdf value ''u''</math>; call this ''x''<sub>''chosen''</sub>.
#Take ''x''<sub>''chosen''</sub> to be the random number drawn from the distribution described by d(''xF'').
 
==Proof of correctness==