general continuous distributions lecture 17, 18huang251/slides18.pdf · general continuous...

52
General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions Expected Value and Variance Percentiles and Quartiles 17, 18.1 Lecture 17, 18 General Continuous Distributions Text: A Course in Probability by Weiss 8.1 8.3 STAT 225 Introduction to Probability Models March 10, 2014 Whitney Huang Purdue University

Upload: others

Post on 27-Jun-2020

6 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.1

Lecture 17, 18General Continuous DistributionsText: A Course in Probability by Weiss 8.1 ∼ 8.3

STAT 225 Introduction to Probability ModelsMarch 10, 2014

Whitney HuangPurdue University

Page 2: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.2

Agenda

1 From Discrete to Continuous Random Variable

2 Cumulative Distribution Functions

3 Expected Value and Variance

4 Percentiles and Quartiles

Page 3: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.3

Probability Mass Functions v.s. Probability DensityFunctions

0 2 4 6 8 10

0.00

0.10

0.20

Pmf for Binomial(n=10,p=0.3)

x

p(x)

0 2 4 6 8 10

0.00

0.10

0.20

Pdf for Normal(mean=5, sd=1.5)

xf(x)

Remarks:pmf assign probabilities to each possible values of adiscrete distributionpdf describes the relative likelihood for this randomvariable to take on a given value

Page 4: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.4

Probability Mass Functions v.s. Probability DensityFunctions cont’d

Recall the properties of discrete probability mass functions(Pmfs):

0 ≤ pX (x) ≤ 1 for all possible values of x

∑x pX (x) = 1

P(a ≤ X ≤ b) =∑x=b

x=a pX (x)For continuous distributions, the properties for probabilitydensity functions (Pdfs) are similar:

fX (x) ≥ 0 for all possible values of x∫∞−∞ fX (x)dx = 1

P(a ≤ X ≤ b) =∫ b

a fX (x)dx

Page 5: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.4

Probability Mass Functions v.s. Probability DensityFunctions cont’d

Recall the properties of discrete probability mass functions(Pmfs):

0 ≤ pX (x) ≤ 1 for all possible values of x∑x pX (x) = 1

P(a ≤ X ≤ b) =∑x=b

x=a pX (x)For continuous distributions, the properties for probabilitydensity functions (Pdfs) are similar:

fX (x) ≥ 0 for all possible values of x∫∞−∞ fX (x)dx = 1

P(a ≤ X ≤ b) =∫ b

a fX (x)dx

Page 6: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.4

Probability Mass Functions v.s. Probability DensityFunctions cont’d

Recall the properties of discrete probability mass functions(Pmfs):

0 ≤ pX (x) ≤ 1 for all possible values of x∑x pX (x) = 1

P(a ≤ X ≤ b) =∑x=b

x=a pX (x)

For continuous distributions, the properties for probabilitydensity functions (Pdfs) are similar:

fX (x) ≥ 0 for all possible values of x∫∞−∞ fX (x)dx = 1

P(a ≤ X ≤ b) =∫ b

a fX (x)dx

Page 7: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.4

Probability Mass Functions v.s. Probability DensityFunctions cont’d

Recall the properties of discrete probability mass functions(Pmfs):

0 ≤ pX (x) ≤ 1 for all possible values of x∑x pX (x) = 1

P(a ≤ X ≤ b) =∑x=b

x=a pX (x)

For continuous distributions, the properties for probabilitydensity functions (Pdfs) are similar:

fX (x) ≥ 0 for all possible values of x∫∞−∞ fX (x)dx = 1

P(a ≤ X ≤ b) =∫ b

a fX (x)dx

Page 8: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.4

Probability Mass Functions v.s. Probability DensityFunctions cont’d

Recall the properties of discrete probability mass functions(Pmfs):

0 ≤ pX (x) ≤ 1 for all possible values of x∑x pX (x) = 1

P(a ≤ X ≤ b) =∑x=b

x=a pX (x)For continuous distributions, the properties for probabilitydensity functions (Pdfs) are similar:

fX (x) ≥ 0 for all possible values of x

∫∞−∞ fX (x)dx = 1

P(a ≤ X ≤ b) =∫ b

a fX (x)dx

Page 9: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.4

Probability Mass Functions v.s. Probability DensityFunctions cont’d

Recall the properties of discrete probability mass functions(Pmfs):

0 ≤ pX (x) ≤ 1 for all possible values of x∑x pX (x) = 1

P(a ≤ X ≤ b) =∑x=b

x=a pX (x)For continuous distributions, the properties for probabilitydensity functions (Pdfs) are similar:

fX (x) ≥ 0 for all possible values of x∫∞−∞ fX (x)dx = 1

P(a ≤ X ≤ b) =∫ b

a fX (x)dx

Page 10: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.4

Probability Mass Functions v.s. Probability DensityFunctions cont’d

Recall the properties of discrete probability mass functions(Pmfs):

0 ≤ pX (x) ≤ 1 for all possible values of x∑x pX (x) = 1

P(a ≤ X ≤ b) =∑x=b

x=a pX (x)For continuous distributions, the properties for probabilitydensity functions (Pdfs) are similar:

fX (x) ≥ 0 for all possible values of x∫∞−∞ fX (x)dx = 1

P(a ≤ X ≤ b) =∫ b

a fX (x)dx

Page 11: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.5

Cumulative Distribution Functions (cdfs) for ContinuousDistribution

The cdf FX (x) is defined asFX (x) = P(X ≤ x) =

∫ x−∞ fX (x)dx

Some properties of the cdf:1 It is non-decreasing

2 It is everywhere right–continuous3 It has the value of 0 for x = −∞, i.e. FX (−∞) = 04 It has the value of 1 for x =∞, i.e. FX (∞) = 1

we use cdf to calculate probabilities of a continuousrandom variable within an interval, i.e.P(a ≤ X ≤ b) =

∫ ba fX (x)dx =∫ b

−∞ fX (x)dx −∫ a−∞ fX (x)dx = FX (b)− FX (a)

Some identities for cdf1 P(a < X < b) = FX (b)− FX (a) =

∫ ba fX (x) dx

2 P(a ≤ X ≤ b) = FX (b)− FX (a) =∫ b

a fX (x) dx

Remark: P(X = x) =∫ x

x fX (x) dx = 0 for all possible values ofx

Page 12: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.5

Cumulative Distribution Functions (cdfs) for ContinuousDistribution

The cdf FX (x) is defined asFX (x) = P(X ≤ x) =

∫ x−∞ fX (x)dx

Some properties of the cdf:1 It is non-decreasing2 It is everywhere right–continuous

3 It has the value of 0 for x = −∞, i.e. FX (−∞) = 04 It has the value of 1 for x =∞, i.e. FX (∞) = 1

we use cdf to calculate probabilities of a continuousrandom variable within an interval, i.e.P(a ≤ X ≤ b) =

∫ ba fX (x)dx =∫ b

−∞ fX (x)dx −∫ a−∞ fX (x)dx = FX (b)− FX (a)

Some identities for cdf1 P(a < X < b) = FX (b)− FX (a) =

∫ ba fX (x) dx

2 P(a ≤ X ≤ b) = FX (b)− FX (a) =∫ b

a fX (x) dx

Remark: P(X = x) =∫ x

x fX (x) dx = 0 for all possible values ofx

Page 13: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.5

Cumulative Distribution Functions (cdfs) for ContinuousDistribution

The cdf FX (x) is defined asFX (x) = P(X ≤ x) =

∫ x−∞ fX (x)dx

Some properties of the cdf:1 It is non-decreasing2 It is everywhere right–continuous3 It has the value of 0 for x = −∞, i.e. FX (−∞) = 0

4 It has the value of 1 for x =∞, i.e. FX (∞) = 1

we use cdf to calculate probabilities of a continuousrandom variable within an interval, i.e.P(a ≤ X ≤ b) =

∫ ba fX (x)dx =∫ b

−∞ fX (x)dx −∫ a−∞ fX (x)dx = FX (b)− FX (a)

Some identities for cdf1 P(a < X < b) = FX (b)− FX (a) =

∫ ba fX (x) dx

2 P(a ≤ X ≤ b) = FX (b)− FX (a) =∫ b

a fX (x) dx

Remark: P(X = x) =∫ x

x fX (x) dx = 0 for all possible values ofx

Page 14: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.5

Cumulative Distribution Functions (cdfs) for ContinuousDistribution

The cdf FX (x) is defined asFX (x) = P(X ≤ x) =

∫ x−∞ fX (x)dx

Some properties of the cdf:1 It is non-decreasing2 It is everywhere right–continuous3 It has the value of 0 for x = −∞, i.e. FX (−∞) = 04 It has the value of 1 for x =∞, i.e. FX (∞) = 1

we use cdf to calculate probabilities of a continuousrandom variable within an interval, i.e.P(a ≤ X ≤ b) =

∫ ba fX (x)dx =∫ b

−∞ fX (x)dx −∫ a−∞ fX (x)dx = FX (b)− FX (a)

Some identities for cdf1 P(a < X < b) = FX (b)− FX (a) =

∫ ba fX (x) dx

2 P(a ≤ X ≤ b) = FX (b)− FX (a) =∫ b

a fX (x) dx

Remark: P(X = x) =∫ x

x fX (x) dx = 0 for all possible values ofx

Page 15: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.6

Example 44

Let us find the cdf of a coin tossing example1 Let n = 4, p = .3, and X be the number of heads in the

sample. Find the cdf for X .2 Keep the above set-up, but use p = .5 instead. What is the

cdf for this r.v.?

Page 16: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.7

Example 44 cont’d

Solution.

1 X ∼ Bin(n = 4,p = 0.3)

FX (x) =

0 if x < 0P(X = 0) = .2401 if 0 ≤ x < 1∑1

i=0 P(X = i) = .6517 if 1 ≤ x < 2∑2i=0 P(X = i) = .9163 if 2 ≤ x < 3∑3i=0 P(X = i) = .9919 if 3 ≤ x < 4∑4i=0 P(X = i) = 1 if x ≥ 4

2 X ∼ Bin(n = 4,p = 0.5)

FX (x) =

0 if x < 0P(X = 0) = .0625 if 0 ≤ x < 1∑1

i=0 P(X = i) = .3125 if 1 ≤ x < 2∑2i=0 P(X = i) = .6875 if 2 ≤ x < 3∑3i=0 P(X = i) = .9375 if 3 ≤ x < 4∑4i=0 P(X = i) = 1 if x ≥ 4

Page 17: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.8

Example 44 cont’d

Solution.

0 1 2 3 4

0.0

0.4

0.8

Cdf for Binomial(n=4,p=0.3)

x

F(x)

0 1 2 3 4

0.0

0.4

0.8

Cdf for Binomial(n=4, p=0.5)

x

F(x)

Page 18: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.9

Example 45

Let us find the cdf of a random experiment over an interval1 Let X denote a number selected at random from the

interval (0,1), what is the cdf of X?2 Let X denote a number selected at random from the

interval (0,10), what is the cdf of X?

Page 19: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.10

Example 45 cont’d

1 FX (x) =

0 x < 0x 0 ≤ x ≤ 11 x > 1

2 FX (x) =

0 x < 0x10 0 ≤ x ≤ 101 x > 10

Page 20: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.11

Example 45 cont’d

Solution.

0.0 0.2 0.4 0.6 0.8 1.0

0.0

0.6

Cdf for Uniform(0,1)

x

F(x)

0 2 4 6 8 10

0.0

0.6

Cdf for Uniform(0,10)

x

F(x)

Page 21: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.12

Expected Value and Variance

Recall the expected value formula for the discrete randomvariable: E[X ] =

∑x xpX (x)

For continuous random variables, we have similar formulas:Let a, b, and c are constant real numbers

E[X ] =∫∞−∞ xfX (x)dx

E[g(X )] =∫∞−∞ g(x)fX (x)dx

E[X + Y ] = E[X ] + E[Y ]

E[cX ] = cE[X ]

E[aX + bY ] = aE[X ] + bE[Y ]

Var(X ) = E[X 2]− (E[X ])2 =∫∞−∞ x2fX (x)dx −

(∫∞−∞ xfX (x)dx

)2

Var(cX ) = c2Var(X )

Var(X − c) = Var(X )

Page 22: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.12

Expected Value and Variance

Recall the expected value formula for the discrete randomvariable: E[X ] =

∑x xpX (x)

For continuous random variables, we have similar formulas:Let a, b, and c are constant real numbers

E[X ] =∫∞−∞ xfX (x)dx

E[g(X )] =∫∞−∞ g(x)fX (x)dx

E[X + Y ] = E[X ] + E[Y ]

E[cX ] = cE[X ]

E[aX + bY ] = aE[X ] + bE[Y ]

Var(X ) = E[X 2]− (E[X ])2 =∫∞−∞ x2fX (x)dx −

(∫∞−∞ xfX (x)dx

)2

Var(cX ) = c2Var(X )

Var(X − c) = Var(X )

Page 23: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.12

Expected Value and Variance

Recall the expected value formula for the discrete randomvariable: E[X ] =

∑x xpX (x)

For continuous random variables, we have similar formulas:Let a, b, and c are constant real numbers

E[X ] =∫∞−∞ xfX (x)dx

E[g(X )] =∫∞−∞ g(x)fX (x)dx

E[X + Y ] = E[X ] + E[Y ]

E[cX ] = cE[X ]

E[aX + bY ] = aE[X ] + bE[Y ]

Var(X ) = E[X 2]− (E[X ])2 =∫∞−∞ x2fX (x)dx −

(∫∞−∞ xfX (x)dx

)2

Var(cX ) = c2Var(X )

Var(X − c) = Var(X )

Page 24: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.12

Expected Value and Variance

Recall the expected value formula for the discrete randomvariable: E[X ] =

∑x xpX (x)

For continuous random variables, we have similar formulas:Let a, b, and c are constant real numbers

E[X ] =∫∞−∞ xfX (x)dx

E[g(X )] =∫∞−∞ g(x)fX (x)dx

E[X + Y ] = E[X ] + E[Y ]

E[cX ] = cE[X ]

E[aX + bY ] = aE[X ] + bE[Y ]

Var(X ) = E[X 2]− (E[X ])2 =∫∞−∞ x2fX (x)dx −

(∫∞−∞ xfX (x)dx

)2

Var(cX ) = c2Var(X )

Var(X − c) = Var(X )

Page 25: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.12

Expected Value and Variance

Recall the expected value formula for the discrete randomvariable: E[X ] =

∑x xpX (x)

For continuous random variables, we have similar formulas:Let a, b, and c are constant real numbers

E[X ] =∫∞−∞ xfX (x)dx

E[g(X )] =∫∞−∞ g(x)fX (x)dx

E[X + Y ] = E[X ] + E[Y ]

E[cX ] = cE[X ]

E[aX + bY ] = aE[X ] + bE[Y ]

Var(X ) = E[X 2]− (E[X ])2 =∫∞−∞ x2fX (x)dx −

(∫∞−∞ xfX (x)dx

)2

Var(cX ) = c2Var(X )

Var(X − c) = Var(X )

Page 26: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.12

Expected Value and Variance

Recall the expected value formula for the discrete randomvariable: E[X ] =

∑x xpX (x)

For continuous random variables, we have similar formulas:Let a, b, and c are constant real numbers

E[X ] =∫∞−∞ xfX (x)dx

E[g(X )] =∫∞−∞ g(x)fX (x)dx

E[X + Y ] = E[X ] + E[Y ]

E[cX ] = cE[X ]

E[aX + bY ] = aE[X ] + bE[Y ]

Var(X ) = E[X 2]− (E[X ])2 =∫∞−∞ x2fX (x)dx −

(∫∞−∞ xfX (x)dx

)2

Var(cX ) = c2Var(X )

Var(X − c) = Var(X )

Page 27: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.12

Expected Value and Variance

Recall the expected value formula for the discrete randomvariable: E[X ] =

∑x xpX (x)

For continuous random variables, we have similar formulas:Let a, b, and c are constant real numbers

E[X ] =∫∞−∞ xfX (x)dx

E[g(X )] =∫∞−∞ g(x)fX (x)dx

E[X + Y ] = E[X ] + E[Y ]

E[cX ] = cE[X ]

E[aX + bY ] = aE[X ] + bE[Y ]

Var(X ) = E[X 2]− (E[X ])2 =∫∞−∞ x2fX (x)dx −

(∫∞−∞ xfX (x)dx

)2

Var(cX ) = c2Var(X )

Var(X − c) = Var(X )

Page 28: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.12

Expected Value and Variance

Recall the expected value formula for the discrete randomvariable: E[X ] =

∑x xpX (x)

For continuous random variables, we have similar formulas:Let a, b, and c are constant real numbers

E[X ] =∫∞−∞ xfX (x)dx

E[g(X )] =∫∞−∞ g(x)fX (x)dx

E[X + Y ] = E[X ] + E[Y ]

E[cX ] = cE[X ]

E[aX + bY ] = aE[X ] + bE[Y ]

Var(X ) = E[X 2]− (E[X ])2 =∫∞−∞ x2fX (x)dx −

(∫∞−∞ xfX (x)dx

)2

Var(cX ) = c2Var(X )

Var(X − c) = Var(X )

Page 29: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.13

Percentiles and Quartiles

A percentile represent the lower percent of the distributionFor example, the 10th percentile, written as X10, meansthat 10% of the distribution is less than or equal to thatvalue. It is the x value such that FX (x) = .10

The first quartile, Q1, represents the bottom (lower) 25% ofthe dataThe second quartile, Q2, aka the median, represents thebottom (lower) 50% of the dataThe third quartile, Q3, represents the bottom (lower) 75%of the data

Page 30: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.13

Percentiles and Quartiles

A percentile represent the lower percent of the distributionFor example, the 10th percentile, written as X10, meansthat 10% of the distribution is less than or equal to thatvalue. It is the x value such that FX (x) = .10The first quartile, Q1, represents the bottom (lower) 25% ofthe data

The second quartile, Q2, aka the median, represents thebottom (lower) 50% of the dataThe third quartile, Q3, represents the bottom (lower) 75%of the data

Page 31: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.13

Percentiles and Quartiles

A percentile represent the lower percent of the distributionFor example, the 10th percentile, written as X10, meansthat 10% of the distribution is less than or equal to thatvalue. It is the x value such that FX (x) = .10The first quartile, Q1, represents the bottom (lower) 25% ofthe dataThe second quartile, Q2, aka the median, represents thebottom (lower) 50% of the data

The third quartile, Q3, represents the bottom (lower) 75%of the data

Page 32: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.13

Percentiles and Quartiles

A percentile represent the lower percent of the distributionFor example, the 10th percentile, written as X10, meansthat 10% of the distribution is less than or equal to thatvalue. It is the x value such that FX (x) = .10The first quartile, Q1, represents the bottom (lower) 25% ofthe dataThe second quartile, Q2, aka the median, represents thebottom (lower) 50% of the dataThe third quartile, Q3, represents the bottom (lower) 75%of the data

Page 33: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.14

Example 46

Let X represent the diameter in inches of a circular disk cut bya machine. Let fX (x) = c(4x − x2) for 1 ≤ x ≤ 4 and be 0otherwise. Answer the following questions:

1 Find the value of c that makes this a valid pdf

2 Find the expected value and variance of X3 What is the probability that X is within .5 inches of the

expected diameter?4 Find FX (x)5 What is the 33rd percentile of X?

Page 34: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.14

Example 46

Let X represent the diameter in inches of a circular disk cut bya machine. Let fX (x) = c(4x − x2) for 1 ≤ x ≤ 4 and be 0otherwise. Answer the following questions:

1 Find the value of c that makes this a valid pdf2 Find the expected value and variance of X

3 What is the probability that X is within .5 inches of theexpected diameter?

4 Find FX (x)5 What is the 33rd percentile of X?

Page 35: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.14

Example 46

Let X represent the diameter in inches of a circular disk cut bya machine. Let fX (x) = c(4x − x2) for 1 ≤ x ≤ 4 and be 0otherwise. Answer the following questions:

1 Find the value of c that makes this a valid pdf2 Find the expected value and variance of X3 What is the probability that X is within .5 inches of the

expected diameter?

4 Find FX (x)5 What is the 33rd percentile of X?

Page 36: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.14

Example 46

Let X represent the diameter in inches of a circular disk cut bya machine. Let fX (x) = c(4x − x2) for 1 ≤ x ≤ 4 and be 0otherwise. Answer the following questions:

1 Find the value of c that makes this a valid pdf2 Find the expected value and variance of X3 What is the probability that X is within .5 inches of the

expected diameter?4 Find FX (x)

5 What is the 33rd percentile of X?

Page 37: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.14

Example 46

Let X represent the diameter in inches of a circular disk cut bya machine. Let fX (x) = c(4x − x2) for 1 ≤ x ≤ 4 and be 0otherwise. Answer the following questions:

1 Find the value of c that makes this a valid pdf2 Find the expected value and variance of X3 What is the probability that X is within .5 inches of the

expected diameter?4 Find FX (x)5 What is the 33rd percentile of X?

Page 38: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.15

Example 46 cont’d

Solution.

1∫ 4

1 fX (x) dx =∫ 4

1 c(4x − x2) dx = 9c = 1⇒ c = 19

2 E[X ] =∫ 4

1 xfX (x) dx = 2.25E[X 2] =

∫ 41 x2fX (x) dx = 5.6

⇒ Var(X ) = E[X 2]− (E[X ])2 = .53753 P(1.75 ≤ X ≤ 2.75) =

∫ 2.751.75 fX (x) dx = .4282

4 FX (x) =∫ x

1 fX (x) dx = 19 (2x2 − x3

3 )− 527 for 1 ≤ X ≤ 4 and

0 if x < 1 and 1 if x > 45 X.33 is the x value such that∫ x

1 fX (x) dx = .33⇒ X.33 = 1.8254

Page 39: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.15

Example 46 cont’d

Solution.

1∫ 4

1 fX (x) dx =∫ 4

1 c(4x − x2) dx = 9c = 1⇒ c = 19

2 E[X ] =∫ 4

1 xfX (x) dx = 2.25E[X 2] =

∫ 41 x2fX (x) dx = 5.6

⇒ Var(X ) = E[X 2]− (E[X ])2 = .5375

3 P(1.75 ≤ X ≤ 2.75) =∫ 2.75

1.75 fX (x) dx = .4282

4 FX (x) =∫ x

1 fX (x) dx = 19 (2x2 − x3

3 )− 527 for 1 ≤ X ≤ 4 and

0 if x < 1 and 1 if x > 45 X.33 is the x value such that∫ x

1 fX (x) dx = .33⇒ X.33 = 1.8254

Page 40: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.15

Example 46 cont’d

Solution.

1∫ 4

1 fX (x) dx =∫ 4

1 c(4x − x2) dx = 9c = 1⇒ c = 19

2 E[X ] =∫ 4

1 xfX (x) dx = 2.25E[X 2] =

∫ 41 x2fX (x) dx = 5.6

⇒ Var(X ) = E[X 2]− (E[X ])2 = .53753 P(1.75 ≤ X ≤ 2.75) =

∫ 2.751.75 fX (x) dx = .4282

4 FX (x) =∫ x

1 fX (x) dx = 19 (2x2 − x3

3 )− 527 for 1 ≤ X ≤ 4 and

0 if x < 1 and 1 if x > 45 X.33 is the x value such that∫ x

1 fX (x) dx = .33⇒ X.33 = 1.8254

Page 41: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.15

Example 46 cont’d

Solution.

1∫ 4

1 fX (x) dx =∫ 4

1 c(4x − x2) dx = 9c = 1⇒ c = 19

2 E[X ] =∫ 4

1 xfX (x) dx = 2.25E[X 2] =

∫ 41 x2fX (x) dx = 5.6

⇒ Var(X ) = E[X 2]− (E[X ])2 = .53753 P(1.75 ≤ X ≤ 2.75) =

∫ 2.751.75 fX (x) dx = .4282

4 FX (x) =∫ x

1 fX (x) dx = 19 (2x2 − x3

3 )− 527 for 1 ≤ X ≤ 4 and

0 if x < 1 and 1 if x > 4

5 X.33 is the x value such that∫ x1 fX (x) dx = .33⇒ X.33 = 1.8254

Page 42: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.15

Example 46 cont’d

Solution.

1∫ 4

1 fX (x) dx =∫ 4

1 c(4x − x2) dx = 9c = 1⇒ c = 19

2 E[X ] =∫ 4

1 xfX (x) dx = 2.25E[X 2] =

∫ 41 x2fX (x) dx = 5.6

⇒ Var(X ) = E[X 2]− (E[X ])2 = .53753 P(1.75 ≤ X ≤ 2.75) =

∫ 2.751.75 fX (x) dx = .4282

4 FX (x) =∫ x

1 fX (x) dx = 19 (2x2 − x3

3 )− 527 for 1 ≤ X ≤ 4 and

0 if x < 1 and 1 if x > 45 X.33 is the x value such that∫ x

1 fX (x) dx = .33⇒ X.33 = 1.8254

Page 43: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.16

Example 47

Let fX (x) = .25x for 1 ≤ x ≤ 3 and 0 otherwise:1 Is X more likely to be within [1,2] or within [2,3]? First

answer this question using logic. Check your answer bycalculating the probabilities

2 What is the probability that X is more than 2.2?3 Find the mean and standard deviation of X4 Find FX (x)5 What value of X represents the top 15% of the

distribution?

Page 44: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.16

Example 47

Let fX (x) = .25x for 1 ≤ x ≤ 3 and 0 otherwise:1 Is X more likely to be within [1,2] or within [2,3]? First

answer this question using logic. Check your answer bycalculating the probabilities

2 What is the probability that X is more than 2.2?

3 Find the mean and standard deviation of X4 Find FX (x)5 What value of X represents the top 15% of the

distribution?

Page 45: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.16

Example 47

Let fX (x) = .25x for 1 ≤ x ≤ 3 and 0 otherwise:1 Is X more likely to be within [1,2] or within [2,3]? First

answer this question using logic. Check your answer bycalculating the probabilities

2 What is the probability that X is more than 2.2?3 Find the mean and standard deviation of X

4 Find FX (x)5 What value of X represents the top 15% of the

distribution?

Page 46: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.16

Example 47

Let fX (x) = .25x for 1 ≤ x ≤ 3 and 0 otherwise:1 Is X more likely to be within [1,2] or within [2,3]? First

answer this question using logic. Check your answer bycalculating the probabilities

2 What is the probability that X is more than 2.2?3 Find the mean and standard deviation of X4 Find FX (x)

5 What value of X represents the top 15% of thedistribution?

Page 47: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.16

Example 47

Let fX (x) = .25x for 1 ≤ x ≤ 3 and 0 otherwise:1 Is X more likely to be within [1,2] or within [2,3]? First

answer this question using logic. Check your answer bycalculating the probabilities

2 What is the probability that X is more than 2.2?3 Find the mean and standard deviation of X4 Find FX (x)5 What value of X represents the top 15% of the

distribution?

Page 48: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.17

Example 47 cont’d

Solution.

1 X is more likely be within [2,3] because fX (x) is increaseswith xP(1 ≤ X ≤ 2) =

∫ 21 fX (x) dx = .375

P(2 ≤ X ≤ 3) =∫ 3

2 fX (x) dx = .625

2 P(X ≥ 2.2) =∫ 3

2.2 fX (x) dx = .52

3 E[X ] =∫ 3

1 xfX (x) dx = 2.1667E[X 2] =

∫ 31 x2fX (x) dx = 5

⇒ Var(X ) = E[X 2]− (E[X ])2 = .3056⇒ Sd(X ) = .55284 FX (x) =

∫ x1 fX (x) dx = 1

8 (x2 − 1) for 1 ≤ X ≤ 3 and 0 if

x < 1 and 1 if x > 35 X.85 is the x value such that∫ x

1 fX (x) dx = .85⇒ X.85 = 2.7928

Page 49: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.17

Example 47 cont’d

Solution.

1 X is more likely be within [2,3] because fX (x) is increaseswith xP(1 ≤ X ≤ 2) =

∫ 21 fX (x) dx = .375

P(2 ≤ X ≤ 3) =∫ 3

2 fX (x) dx = .625

2 P(X ≥ 2.2) =∫ 3

2.2 fX (x) dx = .52

3 E[X ] =∫ 3

1 xfX (x) dx = 2.1667E[X 2] =

∫ 31 x2fX (x) dx = 5

⇒ Var(X ) = E[X 2]− (E[X ])2 = .3056⇒ Sd(X ) = .55284 FX (x) =

∫ x1 fX (x) dx = 1

8 (x2 − 1) for 1 ≤ X ≤ 3 and 0 if

x < 1 and 1 if x > 35 X.85 is the x value such that∫ x

1 fX (x) dx = .85⇒ X.85 = 2.7928

Page 50: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.17

Example 47 cont’d

Solution.

1 X is more likely be within [2,3] because fX (x) is increaseswith xP(1 ≤ X ≤ 2) =

∫ 21 fX (x) dx = .375

P(2 ≤ X ≤ 3) =∫ 3

2 fX (x) dx = .625

2 P(X ≥ 2.2) =∫ 3

2.2 fX (x) dx = .52

3 E[X ] =∫ 3

1 xfX (x) dx = 2.1667E[X 2] =

∫ 31 x2fX (x) dx = 5

⇒ Var(X ) = E[X 2]− (E[X ])2 = .3056⇒ Sd(X ) = .5528

4 FX (x) =∫ x

1 fX (x) dx = 18 (x

2 − 1) for 1 ≤ X ≤ 3 and 0 ifx < 1 and 1 if x > 3

5 X.85 is the x value such that∫ x1 fX (x) dx = .85⇒ X.85 = 2.7928

Page 51: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.17

Example 47 cont’d

Solution.

1 X is more likely be within [2,3] because fX (x) is increaseswith xP(1 ≤ X ≤ 2) =

∫ 21 fX (x) dx = .375

P(2 ≤ X ≤ 3) =∫ 3

2 fX (x) dx = .625

2 P(X ≥ 2.2) =∫ 3

2.2 fX (x) dx = .52

3 E[X ] =∫ 3

1 xfX (x) dx = 2.1667E[X 2] =

∫ 31 x2fX (x) dx = 5

⇒ Var(X ) = E[X 2]− (E[X ])2 = .3056⇒ Sd(X ) = .55284 FX (x) =

∫ x1 fX (x) dx = 1

8 (x2 − 1) for 1 ≤ X ≤ 3 and 0 if

x < 1 and 1 if x > 3

5 X.85 is the x value such that∫ x1 fX (x) dx = .85⇒ X.85 = 2.7928

Page 52: General Continuous Distributions Lecture 17, 18huang251/slides18.pdf · General Continuous Distributions From Discrete to Continuous Random Variable Cumulative Distribution Functions

General ContinuousDistributions

From Discrete toContinuous RandomVariable

Cumulative DistributionFunctions

Expected Value andVariance

Percentiles andQuartiles

17, 18.17

Example 47 cont’d

Solution.

1 X is more likely be within [2,3] because fX (x) is increaseswith xP(1 ≤ X ≤ 2) =

∫ 21 fX (x) dx = .375

P(2 ≤ X ≤ 3) =∫ 3

2 fX (x) dx = .625

2 P(X ≥ 2.2) =∫ 3

2.2 fX (x) dx = .52

3 E[X ] =∫ 3

1 xfX (x) dx = 2.1667E[X 2] =

∫ 31 x2fX (x) dx = 5

⇒ Var(X ) = E[X 2]− (E[X ])2 = .3056⇒ Sd(X ) = .55284 FX (x) =

∫ x1 fX (x) dx = 1

8 (x2 − 1) for 1 ≤ X ≤ 3 and 0 if

x < 1 and 1 if x > 35 X.85 is the x value such that∫ x

1 fX (x) dx = .85⇒ X.85 = 2.7928