Example: biology

Chapter 4 RANDOM VARIABLES - University of Kent

Chapter 4 RANDOMVARIABLESE xperiments whose outcomes arenumbersEXAMPLE:Selectitemsat randomfrom a batch of sizeNuntil the first defective item is number of non-defective Space:S={0,1,2,..,N}The result from the experiment becomes avariable; that is, a quantity taking differentvalues on different occasions. Because theexperiment involves selection at RANDOM , wecall it arandom : rvNotation: capital letter, :The set of possible values that a randomvariableXcan take is called RandomExperiment VariableEXSample space range ofXOutcome ofEOne possible valuexforXEventSubset of range ofXEventAx subset of range ,x= 3 or 2 x 4Pr(A)Pr(X= 3),Pr(2 X 4)REMINDER:The set of possible values that a randomvariable (rv)Xcan take is called :A rvXis said to bediscreteif its rangeconsists of afiniteorcountablenumber : based on tossing a coin repeatedlyNo.

behaviour of a (discrete) random variable. In practice we often want a more concise description of its behaviour. DEFINITION: The mean or expectation of a discrete rv X, E(X), is defined as E(X) = X x xPr(X = x). Note: Here (and later) the notation X x means the sum over all values x in the range of X. The expectation E(X) is a weighted ...

Tags:

  Name, Variable, Random, Random variables

Information

Domain:

Source:

Link to this page:

Please notify us if you found a problem with this document:

Other abuse

Transcription of Chapter 4 RANDOM VARIABLES - University of Kent

1 Chapter 4 RANDOMVARIABLESE xperiments whose outcomes arenumbersEXAMPLE:Selectitemsat randomfrom a batch of sizeNuntil the first defective item is number of non-defective Space:S={0,1,2,..,N}The result from the experiment becomes avariable; that is, a quantity taking differentvalues on different occasions. Because theexperiment involves selection at RANDOM , wecall it arandom : rvNotation: capital letter, :The set of possible values that a randomvariableXcan take is called RandomExperiment VariableEXSample space range ofXOutcome ofEOne possible valuexforXEventSubset of range ofXEventAx subset of range ,x= 3 or 2 x 4Pr(A)Pr(X= 3),Pr(2 X 4)REMINDER:The set of possible values that a randomvariable (rv)Xcan take is called :A rvXis said to bediscreteif its rangeconsists of afiniteorcountablenumber : based on tossing a coin repeatedlyNo.

2 Of H in 1st 5 tosses:{0,1,2,..,5}No. of T before first H:{0,1,2,..}Note:although the definition of a discrete rvallows it to takeanyfinite or countable set ofvalues, the values are in practice almostalways Distributionsor How todescribethe behaviour of a rv Suppose that the only values a randomvariableXcan take arex1,x2,..,xn. Thatis, therangeofXis the set ofnvaluesx1,x2,.. we can list all possible values, thisrandom variableXmust the behaviour ofXis completelydescribed by giving the probabilities of allrelevant events:EventProbabilityX=x1Pr(X=x1)X=x2P r(X=x2)..X=xnPr(X=xn)In other words, we specify the functionPr(X=x)for all valuesxin the range :TheProbability Functionof adiscreterandom variableXis the functionp(x)satisfyingp(x) = Pr(X=x)for all valuesxin the range : pfNotation:p(x) orpX(x).

3 We use thepX(x)form when we need to make the identity ofthe rv : The pf is sometimes given thealternative name ofprobability mass function(pmf).EXAMPLE:Let the probability of a head on any toss of aparticular coin bep. From independentsuccessive tosses of the coin, we record thenumberXof tails before the first ofX:{0,1,2,..}Pr(X= 0) =pPr(X= 1) = (1 p) (X=x) = (1 p) probability function for the randomvariableXgives a convenient summary of itsbehaviour; the pfpX(x) is given by:pX(x) = (1 p)xp,x= 0,1,2,..Xis said to have aGeometric of a pfIfpX(x) is the pf of a rvX, then pX(x) 0, for allxin the range ofX. pX(x) = 1, where the sum is takenover the range definition of a distribution:The pf of a discrete rv describes how thetotal probability, 1, is split, or distributed,between the various possible values split or pattern is known as thedistributionof the : The pf is not theonlyway ofdescribing the distribution of a discrete 1 1 function of the pf will :Thecumulative distribution functionof arvXis the functionFX(x) ofxgiven byFX(x) = Pr(X x),for all valuesxin the range : cdfTerminology: The cdf is sometimes given thealternative name ofdistribution :F(x) orFX(x).

4 We use theFX(x)form when we need to make the identity ofthe rv with pf: For adiscretervX,FX(x) = y xpX(y)Example: If a rv has range{0,1,2,..},FX(3) =pX(0) +pX(1) +pX(2) +pX(3)andpx(2) =FX(2) FX(1).EXAMPLE:Discrete Uniform DistributionThe rvXis equally likely to take each integervalue in the range 1,2,.., function:pX(x) = 1n,x= 1,2,..,n,0 distribution function:FX(x) = 0,x<1,[x]n,1 x n,1,x n,where [x] is the integer part : The cdf is defined forallvalues ofx,not just the ones in the range this distribution, the cdf is1nfor all valuesofxin the range 1 x<2, then jumps to2n,and so of cdfs:All cdfs are monotonic non-decreasing, satisfyFX( ) = 0, satisfyFX( ) = satisfying these conditions canbe a functionnotsatisfying these conditionscannot be a adiscreterv the cdf is always : Properties of cdfs:Anyfunctionsatisfying the following conditions can be acdf: It is monotonic non-decreasing, It satisfiesFX( ) = 0, It satisfiesFX( ) =.

5 A RANDOM variable is said tobecontinuousif its cdf is a continuousfunction (see later).This is an important case, which occursfrequently in :The Exponential DistributionConsider the rvYwith cdfFY(y) = 0,y<0,1 e y,y meets all the requirements above, and isnot a step cdf is of RANDOM variableMost rvs are either discrete or continuous,but one can devise some complicatedcounter-examples, and there are practical examples of rvswhich are partly discrete and : Cars pass a roadside point, thegaps (in time) between successive cars beingexponentially arrives at the roadside and crossesas soon as the gap to the next car exceeds 10seconds. The rvTis the delay before theperson starts to cross the delayTmay be zero or positive.

6 Thechance thatT= 0 is positive; the cdf has astep att= 0. But fort>0 the cdf will and VarianceThe pf gives acompletedescription of thebehaviour of a (discrete) RANDOM variable . Inpractice we often want a more concisedescription of its :Themeanorexpectationofa discrete rvX, E(X), is defined asE(X) = xxPr(X=x).Note: Here (and later) the notation xmeansthe sum over all valuesxin the range expectation E(X) is a weighted averageof these values. The weights always sum to : The concept of expectation canbe generalised; we can define the expectationofany functionof a rv. Thus we obtain, for afunctiong( ) of a discrete rvX,E{g(X)}= xg(x)Pr(X=x).Measures of variabilityTwo rvs can have equal means but verydifferent patterns of variability.

7 Here is asketch of the probability functionsp1(x) andp2(x) of two (x)xmean6meanp2(x)xTo distinguish between these, we need ameasure of spread of dispersionThere are many possible measures. We lookbriefly at three plausible Mean difference : E{X E(X)}.Attractive superficially, but no Mean absolute difference: E{|X E(X)|}.Hard to manipulate : E{X E(X)} most frequently-used for variance: V(X) or Var(X).That is: V(X) = Var(X) = E{X E(X)} and formulaThe most important features of a distributionare its location and dispersion, measured : E(X) = xxPr(X=x) = .Variance:Var(X) = x(x )2Pr(X=x)= x(x2 2 x+ 2)Pr(X=x)= xx2Pr(X=x) 2 + 2 1= E(X2) {E(X)}2 Reminder: The notation xmeans the sumover all valuesxin the range : We often denote E(X) by , andVar(X) by :We find the mean and variance for therandom variableXwith pf as in the table:x1 2 3 4 5p(x) = Pr(X=x) (X) = xxPr(X=x), soE(X) = (1 ) + (2 ) + (3 )+(4 ) + (5 ) = (X) = E(X2) {E(X)}2, andE(X2) = (12 ) + (22 ) + (32 )+(42 )+(52 ) = ,so Var(X) = ( )2= deviation ofX: , or concepts of expectation and varianceapply equally to discrete and continuousrandom VARIABLES .

8 The formulae givenhere relate todiscretervs; formulae need(slight) adaptation for the : themeanis in the same units asX, thevarianceVar(X), defined asVar(X) = E{X E(X)}2is measure of dispersion in the same unitsasXis thestandard deviation ( ) (X) = Var(X).CONTINUOUS RANDOMVARIABLESI ntroductionReminder: a rv is said to becontinuousif itscdf is the functionFX(x) = Pr(X x) ofxiscontinuous, what is Pr(X=x)?Pr(X=x) = Pr(X x) Pr(X<x)= 0,by continuityA continuous RANDOM variable does notpossess a probability cannot be assigned to individualvalues of x; instead, probability is assigned tointervals. [Strictly, half-open intervals]Consider the events{X a}and{a<X b}.

9 These events are mutually exclusive, and{X a} {a<X b}={X b}.So the addition law of probability (axiomA3)gives:Pr(X b) = Pr(X a) + Pr(a<X b),or Pr(a<X b) = Pr(X b) Pr(X a)=FX(b) FX(a).So, given the cdf for any continuous randomvariableX, we can calculate the probabilitythatXlies in any : The probability Pr(X=a) that acontinuous rvXisexactlyais 0. Because ofthis, we often do not distinguish betweenopen, half-open and closed intervals forcontinous : We gave earlier an example of acontinuous cdf:FY(y) = 0,y<0,1 e y,y is the cdf of what is termed theexponential distributionwith mean the case of that distribution, we can findPr(Y 1) =FY(1) = 1 e 1= (2 Y 3) =FY(3) FY(2)= (1 e 3) (1 e 2) = (Y ) =FY( ) FY( )= 1 (1 e ) = density functionIfXis continuous, then Pr(X=x) = what is the probability that Xis close tosome particular valuex?

10 Consider Pr(x<X x+h),for :dFX(x)dx'FX(x+h) FX(x) Pr(x<X x+h) =FX(x+h) FX(x)'hdFX(x) :The derivative ( ) ofthe cdf of a continous rvXis called theprobability density probability density function is the limit ofPr(x<X x+h)hash probability density functionAlternative names: pdf,density function, for pdf:fX(x)Recall: The cdf ofXis denoted byFX(x)Relationship:fX(x) =dFX(x)dxCare needed: Make surefandFcannot beconfused!Interpretation When multiplied by a small numberh,the pdf gives, approximately, the probabilitythatXlies in a small interval, lengthh, closetox. If, for example,fX(4) = 2fX(7),thenXoccurs near 4 twice as often as near of probability density functionsBecause the pdf of a rvXis the derivative ofthe cdf ofX, it follows that fX(x) 0,for allx, fX(x)dx= 1, FX(x) = x fX(y)dy, Pr(a<X b) = bafX(x) and VarianceReminder: for a discrete rv, the formulae formean and variance are based on theprobability functionPr(X=x).


Related search queries