pro band stat

27
Probability and Statistics 2141-375 Measurement and Instrumentation

Upload: sunu-pradana

Post on 06-Apr-2018

218 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 1/27

Probability and Statistics

2141-375Measurement and Instrumentation

Page 2: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 2/27

Statistical Measurement Theory

A sample of data refers to a set of data obtained during repeatedmeasurements of a variable under fixed operating conditions.

The estimation of true mean value, µ µµ µ  from the repeatedmeasurements of the variable, x. So we have a sample of variable of x under controlled, fixed operating conditions from a finite number 

of data points  .

%)(Pu x  x±=µ 

 x is the sample mean

 xu is the confidence interval or uncertainty in the estimation at someprobability level, P%. The confidence interval is based both on

estimates of the precision error and on bias error in the measurementof x. (in this chapter, we will estimation µ µµ µ  and the precision error in x caused 

 only by the variation in the data set)

Page 3: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 3/27

Infinite Statistics: Normal Distribution

µ µµ µ  is the true mean and σ σσ σ 2 is the true variance of x

A common distribution found in measurements e.g. the measurement oflength, temperature, pressure etc.

])(

2

1exp[

2

1)(

2

2

σ 

µ 

π σ 

−−=

x x p

The probability density function for a random variable, x having normal

distribution is defined as

The probability, P( x) within the interval a and b is given by the area under p( x)

∫ =≤≤

b

a

dx x pb xaP )()(

),(~ 2σ µ  N  X 

Notation for random variable X has a normal distribution with mean µ µµ µ and σ σσ σ 

variance

Page 4: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 4/27

The Standard Normal Distribution

for -∞∞∞∞ ≤≤≤≤ x ≤≤≤≤ ∞ ∞∞ ∞ 

The standard normal distribution:

]2

1exp[

2

1)(

2 x x p −=

π 

The cumulative distribution function of a standard normal distribution

The Normal error function

∫  −=≤≤

a

dx

 x

a xP0

2

]2exp[2

1

)0( π 

)1,0(~ N  X 

The probability density function has the notation, p( x)

dy y p xP x

 )()( ∫ ∞−= ∫ 

∞−

−=≤≤−∞a

dx x

a xP ]

2

exp[

2

1)(

2

π 

Page 5: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 5/27

The Standard Normal Distribution

-3 -2 -1 0 1 2 3

]2

1exp[

2

1)(

2 x x p −=

π 

)1,0( N 

1=σ  1=σ 

∫ ∞−

−= x

dz z xP ]2

1exp[

2

1)( 2

π 

-3 -2 -1 0 1 2 3

0.5

1

The standard normal distribution The cumulative distribution ofthe standard normal distribution

0=

 x  x

Page 6: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 6/27

T h e S t a n d a r d N o r m a l D i s t r i b u t i o n

 N (0,1)

ΦΦΦΦ( x)

x

)()( xZPx ≤=Φ

The symmetry of the standard normal distribution about 0 implies that if therandom variable Z has a standard variable normal distribution, then

)()()()(1 x x Z P x Z P x −Φ=−≤=≥=Φ−

1)()( =−Φ+Φ x x

Page 7: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 7/27

Probability Calculations for Normal Distribution

If X ~ N (µ µµ µ ,σ σσ σ  2), then

 

 

 

  −≤−

 

 

 

  −≤=≤≤

σ 

µ 

σ 

µ  a Z P

b Z Pb xaP )(

The random variable Z is known as the “standardized” version of the randomvariable, X . This results implies that the probability values of a general normal

distribution can be related to the cumulative distribution of the standardnormal distribution ΦΦΦΦ( x) through the relation

)1,0(~ N  X  Z σ −=

 

  

  −Φ−

 

  

  −Φ=

σ 

µ 

σ 

µ  ab

Page 8: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 8/27

The Normal Distribution

-3 -2 -1 0 1 2 3

)( x p

68.27%

95.45%

99.73%

 N (0,1)

There is a probability about 68% that a normal random variable takes avalue within one SD of its mean

There is a probability about 95% that a normal random variable takes avalue within two SD of its mean

There is a probability about 99.7% that a normal random variable takes avalue within three SD of its mean

Normal random variables

)()( c Z cPc xcP ≤≤−=+≤≤− σ σ 

If X ~ N (µ µµ µ ,σ σσ σ  2), notice that

Page 9: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 9/27

The Normal Distribution

Example: It is known that the statistics of a well-defined voltage signal are given by µ = 8.5 V and

σ2 = 2.25 V2. If a single measurement of the voltage signal is made, determine the probability thatthe measured value will be between 10.0 and 11.5 V

Known: µµµµ = 8.5 V and σσσσ2 = 2.25 V2

P(10.0 ≤ x ≤ 11.5) = P( x ≤ 11.5) – P( x ≤ 10.0)

Solution:

Assume: Signal has a normal distribution

P(10.0 ≤ x ≤ 11.5) = 0.1359

=P[ Z ≤ (11.5-8.5)/1.5] – P[ Z ≤ (10.0-8.5)/1.5]

=P[ Z ≤ 2] – P[ Z ≤ 1]

=0.9772 – 0.8413

Page 10: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 10/27

Finite Statistics: Sample Versus Population

Population Sample

Populationparameters

Samplestatistics

Statistical

Inference

Randomselection

(experiment)

The finite sample versus the infinite population

Parameter is a quantity that is a property of unknown probability distribution. Thismay be the mean, variance or a particular quantity.

Statistic is a quantity that is a property of sample. This may be the mean, varianceor a particular quantity. Statistics can be calculated from a set of data observations.

Estimation is a procedure by which the information contained within a sample isused to investigate properties of the population from which the sample is drawn.

Page 11: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 11/27

Population mean(unknown)

µData observations (known)

Sample mean(known)

 x=ˆ

Probability density function

(unknown)

Point Estimates of Parameters

A point estimate of unknown parameter θ θθ θ  is a statistic θ θθ θ  that represent of a “bestguess” at the value of θ θθ θ .

Estimation of the population mean by the sample mean

Unknown parameter θ θθ θ 

Probability distribution f ( x,θ θθ θ )

Data observation x1,… xn (sample)

Point estimate (statistic) θ θθ θ 

unknown

Known by experiment

Page 12: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 12/27

Point Estimation of Mean and Variance

Sample mean: Point Estimate of a Population Mean

∑=

== N 

i

i x N 

 x1

1µ̂ 

( )∑=

−−

== N 

i

i x x x N 

S1

222

1

1σ̂ 

If X 1, …, X n is a sample of observation from a probability distribution which a mean

µµµµ, then the sample mean

is the best guess of the point estimate of the population mean µµµµSample variance: Point Estimate of a Population Variance:

If X 1, …, X n is a sample of observation from a probability distribution which a

variance σσσσ2, then the sample variance

is the best guess of the point estimate of the population variance σσσσ2

Page 13: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 13/27

Inference of Population Mean

%)(, PSt  x x  xPvi ±∈

Where the variable tv,p is a function of the probability P, and the degree offreedom v = n - 1 of the Student- t distribution.

The estimate of the true mean value based on a finite data set is

For a normal distribution of x about some sample mean value, x one canstate that

( ) ( ) or,

,,,, xPv xPv xPv xPv

St  x ,n / St  xSt  xSt  x +−∈+−∈ µ µ 

The standard deviation of the mean

 N 

SS x

 x =

Page 14: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 14/27

Inference of Population Mean

( ) %)(, Pu xu x  x x +−∈µ 

 x

µ ˆ

  xu x −   xu x +

Precision error u x

with confident level P or 1 - α αα α 

Inference methods on a population mean based on the t-procedure for

large sample size n ≥≥≥≥ 30 and also for small sample sizes as long as the data canreasonably be taken to be approximately normally distributed. Nonparametric

techniques can be employed for small sample sizes with data that are clearly notnormally distributed

Page 15: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 15/27

Example: Consider the data in the table below. (a) Compute the sample statistics for this data set.(b) Estimate the interval of values over which 95% of the measurements of the measurand should

be expected to lie. (c) Estimate the true mean value of the measurand at 95% probability based onthis finite data set

Known: the given table, N = 20

Solution:

Assume: data set follows a normal distribution

Inference of Population Mean

i  x ii  x i

1 0.98 11 1.02

2 1.07 12 1.26

3 0.86 13 1.084 1.16 14 1.02

5 0.96 15 0.94

6 0.68 16 1.11

7 1.34 17 0.99

8 1.04 18 0.789 1.21 19 1.0610 0.86 20 0.96

Page 16: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 16/27

Inference of Population Variance

222

 / ~ σ  χ   xvS

with the degree of freedom v = n - 1

For a normal distribution of x, sample variance S2 has a probability density

function of chi-square χχχχ2

Precision Interval in a Sample Variance

α α α  −=≤≤ 1)χ χ χ ( 2

 /2

22

 /2-1P

α σ  α α  −=≤≤ 1) / χ  / χ ( 2

 /2-1

222

 /2

2

 x x vSvSP

)1( ) / χ , / χ ( 2

 /2-1

22

 /2

22 α σ α α 

−=∈ PvSvS x x

with a probability of P(χχχχ2) = 1- αααα

Page 17: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 17/27

Example: Ten steel tension specimens are tested from a large batch, and a sample variance of(200 kN/m2)2 is found. State the true variance expected at 95% confidence.

Known: S2 = 40000 (kN/m2)2, N = 10

Solution: assume data set follows a normal distribution, with v = n - 1 = 9

Inference of Population Variance

From chi-square table χχχχ2 = 19 at αααα = 0.025 and χχχχ2 = 2.7 at αααα = 0.975

7.2 / 40000919 / 400009 2 ⋅≤≤⋅ σ 

%)95( 365138 222 ≤≤σ 

Page 18: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 18/27

Pooled Statistics

Consider M replicates of a measurement of a variable, x, each of N 

repeated readings so as to yield that data set xij, where i = 1,2,…, N and j =

1, 2, …, M .

∑∑= =

= M 

 j

 N 

i

ij x MN 

 x1 1

1

The pooled mean of x

With degree of freedom v = M ( N -1)

The pooled standard deviation of x

∑∑∑== =

=−−

= M 

 j

 x

 M 

 j

 N 

i

 jij x  jS

 M  x x

 N  M S

1

2

1 1

2 1)(

)1(

1

The pooled standard deviation of the means of x

2 / 1

)( MN 

SS

x

 x =

Page 19: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 19/27

Data outlier detection

Detect data points that fall outside the normal range of variation expected in adata set base on the variance of the data set. This range is defined by some

multiple of the standard deviation.

Ex. 3-sigma method: consider all data points that lie outside the range of 99.8%

probability, as outlier.8.99, xv St  x ±

Modified 3-sigma method: calculated the z variable of each data point by

  x

i

S

 x x z

−=

The probability that x lies outside range defined by -∞∞∞∞ and z is 1 - P( z). For N data points is N [1 – P( z)] ≤≤≤≤ 0.1, the data points can be considered as outlier.

Page 20: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 20/27

Example: Consider the data given here for 10 measurements of tire pressure taken with aninexpensive handheld gauge. Compute the statistics of the data set; then test for outlier by using

the modified three-sigma test

Known: N = 10

Solution:

Assume: Each measurement obtained under fixed conditions

Data outlier detection

 n i  x [psi] |z|  P (| z| )  N (1- P(| z|)1 28 0.3 0.6199 3.8010

2 31 1.1 0.8724 1.2764

3 27 0.0 0.5111 4.8893

4 28 0.3 0.6199 3.8010

5 29 0.6 0.7199 2.80056 24 0.8 0.7895 2.1051

7 29 0.6 0.7199 2.8005

8 28 0.3 0.6199 3.8010

9 18 2.5 0.9932 0.0677

10 27 0.0 0.5111 4.8893

 N = 10: x = 27, S x = 3.604

 N = 9: x = 28, S x = 2.0, t8,95 = 2.306

(95%) psi6.128, ±=±= N 

St  x

xPvµ 

After removing the spurious data

Statistics at start

Page 21: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 21/27

Number of Measurement

The precision interval is two sided about sample mean that true mean to bewithin. to . Here, we define the one-side precision value d as

  / , N St   xPv−   / , N St   xPv+

 N 

St d 

xv,P  =

The required number of measurement is estimated by

2

Pd St  N  xv,P

  

  ≈

The estimated of sample variance is needed. If we do a preliminary smallnumber of measurements, N 1 for estimate sample variance, S1. The total number

of measurements, N T will be

2

111 Pd 

St  N 

,P N 

T   

  

 ≈ −

 N T 

– N 1

additional measurements will be required.

Page 22: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 22/27

Example: Determine the number of measurements required to reduce the confidential interval ofthe mean value of a variable to within 1 unit if the variance of the variable is estimated to be ~64

units.

Known: P = 95% d = ½ σ σσ σ 2 = 64 units

 N = 983Solution:

Assume: σ σσ σ 2 ≈≈≈≈ S2 x

Number of Measurement

5%9 

2

 

  

 ≈ d 

St  N 

xv,P

Page 23: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 23/27

The regression analysis for a single variable of the form y = f ( x) provides an

mth order polynomial fit of the data in the form. variable

Least-Square Regression Analysis

Where y c is the value of the dependent variable obtained directly from thepolynomial equation for a given value of x. For N different values of

independent and dependent value included in the analysis, the highest order, m,of the polynomial that can be determined is restricted to m ≤≤≤≤ N – 1.

The values of the  m + 1 coefficients a0, a1, …, am are determined by the leastsquare method. The least-squares technique attempts to minimize the sum of

the square of the deviations between the actual data and the polynomial fit

m

mc xa xa xaa y ++++= ...2210

∑=

−= N 

i

ci y y D1

2)(Minimize

Page 24: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 24/27

Least-Square Regression Analysis

( )[ ]∑=

++++−= N 

i

m

mi xa xa xaa y D1

2

210 ...

To minimize the sum of square error, one wants dD to be zero. This is

accomplished by setting each of the partial derivatives equal to zero

Now the total differential of D is dependent on the m + 1 coefficients

m

m

daa

 Dda

a

 Dda

a

 Dda

a

 DdD

∂∂

++∂∂

+∂∂

+∂∂

= ...2

2

1

1

0

0

[ ]

[ ]

[ ]

+++−∂

∂==

+++−∂∂

==∂∂

+++−∂∂

==∂∂

=

=

=

 N 

i

m

mi

mm

 N 

i

m

mi

 N 

i

m

mi

 xa xaa y

aa

 D

 xa xaa yaa

 D

 xa xaa yaa

 D

1

2

10

1

2

10

11

1

2

10

00

...(0

...(0

...(0

Page 25: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 25/27

Least-Square Regression Analysis

This yields m + 1 equations, which are solved simultaneously to yield theunknown regression coefficients, a0, a1, …, am

v

 y y

S

 N 

i

ci

 yx

∑=

−= 1

2)(

Standard deviation based on the deviation of the each data point and the fit by

A measure of the precision

We can state that the curve fit with its precision interval as

%)(, PSt  y  yxPvc ±

Page 26: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 26/27

Page 27: Pro Band Stat

8/2/2019 Pro Band Stat

http://slidepdf.com/reader/full/pro-band-stat 27/27

Least-Square Regression Analysis

Example: The following data are suspected to follow a linear relationship. Find an appropriateequation of the first-order form

Known: Independent variable, x

Dependent variable, y N = 5

Solution:

Assume: Linear relation

 x [cm]  y [V]

1 1.22 1.9

3 3.2

4 4.1

5 5.3

 yc = a0 + a1 x

x[cm] y[V] x2

y2

xy

1 1.2 1 1.44 1.2

2 1.9 4 3.61 3.83 3.2 9 10.24 9.6

4 4.1 16 16.81 16.4

5 5.3 25 28.09 26.5

ΣΣΣΣ 15 15.7 55 60.19 57.5

 yc = 0.02 + 1.04 x

νννν = N - (m+1) = 5 - (1+1) = 3