Stat 106
Stat 106
Stat 106
2.1.
Introduction:
2.2.
Mean:
(1) Population mean :
If X1,X2, , XN are the population values of the variable of
interest , then the population mean is:
N
X
X1 X 2 X N i 1 i
N
N
(unit)
x x2 xn
x 1
x
i 1
(unit)
Example:
Consider the following population values:
Then:
30 22 35 27 41 155
31
5
5
30 35 27 92
x
30.67
3
3
(unit)
(unit)
Notes:
The mean is simple to calculate.
There is only one mean for a given sample data.
The mean can be distorted by extreme values.
The mean can only be found for quantitative variables
Median:
The median of a finite set of numbers is that value which
divides the ordered set into two equal parts.
Let x1,x2, , xn be the sample values . We have two cases:
(1)
n 1
The median = The
order observation.
2
Ordered set
(smallest to largest)
Rank (or order)
*
1
Middle
value=
MEDIAN
n 1
2
Example:
Find the median for the sample values: 10, 54, 21, 38, 53.
Solution:
n = 5 (odd number)
n 1
The rank of the middle value (median) = 2 = (5+1)/2 = 3
Ordered set 10 21
Rank (or order) 1
The median =38 (unit)
38
53
54
n 1
=3
2
(2)
The median is the mean (average) of the two middle values of the
ordered observations.
n
n
The middle two values are the ordered and2 1 observations.
2
The median =
Ordered set
Example:
Find the median for the sample values: 10, 35, 41, 16, 20, 32
Solution:
.n = 6 (even number)
The rank of the middle values are
n
=6/2=3
2
n
1
2
= (6 / 2) + 1 = 4
Ordered set
Rank (or order)
The median
20 32 52
26 (unit)
2
2
Note:
The median is simple to calculate.
There is only one median for given data.
he median is not affected too much by extreme values.
The median can only be found for quantitative variables
Mode:
The mode of a set of values is that value which occurs with the
highest frequency.
Example:
Note:
The mode is simple to calculate but it is not good.
The mode is not affected too much by extreme values.
The mode may be found for both quantitative and qualitative
variables.
2.3.
Smaller variation
Larger variation
Range:
Range is the difference between the largest (Max) and smallest
(Min) values.
Range = Max Min
Example:
Find the range for the sample values: 26, 25, 35, 27, 29, 29.
Solution:
Range = 35 25 = 10 (unit)
Note:
The range is not useful as a measure of the variation since it only
takes into account two of the values. (it is not good)
Variance:
The variance is a measure that uses the mean as a point of
reference.
The variance is small when all values are close to the mean. The
variance is large when all values are spread out from the mean.
deviations from the mean:
(1)
Population variance:
Let X1,X2, , XN be the population values.
The population variance is defined by
where
mean
Xi
i 1
is the population
(2)
Sample Variance:
where x
xi
i 1
Example:
We want to compute the sample variance of the following sample
values: 10, 21, 33, 53, 54.
Solution: n=5
Another method:
Note:
To calculate S2 we need:
n = sample size
xi The sum of the values
2
x
7355 5 34.2
1506.8
S
376.7
5 1
4
2
Standard Deviation:
2
S2
(unit)
(unit)
We need a measure of the relative variation that
will not depend on either the units or on how large the
values are. This measure is the coefficient of variation
(C.V.) which is defined by:
S
*100
C.V. =
(free%of unit or unit less)
x
Mean
St.dev.
C.V.
1st data set
2nd data set
x1
S1
x2
S2
C.V1
C.V2
S1
100%
x1
S2
100%
x2
The relative variability in the 1st data set is larger than
the relative variability in the 2nd data set if C.V1> C.V2 (and vice
versa).
Example:
S2
st
x
1
1 data set:
66 kg,
4.5 kg
C .V1
4.5
*100 % 6.8 %
66
x 2 36 kg,
C.V 2
S 2 4.5 kg
4.5
* 100% 12.5%
36
Sample Sample
st.dev Variance
2
aS
a2S 2
ax1 , ax 2 , , ax n
x
ax
x1 b, , , xn b
xb
S2
ax1 b, , ax n b
ax b
aS
a2S 2
x1 , x2 , , xn
Absolute value:
a
a
if a 0
if a 0
Example:
(1)
(2)
(3)
Data
Sample
Sample
mean
Sample
St..dev.
Sample
Variance
1,3,5
-6
13
4
4
2
4
16
4
16
(1) 2 x1 ,2 x2 ,2 x3
(a = 2)
(b = 10)
(a = 2, b = 10)