Introduction to Business Statistics Introduction to Business - - PowerPoint PPT Presentation

introduction to business statistics introduction to
SMART_READER_LITE
LIVE PREVIEW

Introduction to Business Statistics Introduction to Business - - PowerPoint PPT Presentation

DEPARTMENT OF QUANTITATIVE METHODS & INFORMATION SYSTEMS Introduction to Business Statistics Introduction to Business Statistics QM 120 Ch Chapter 3 t 3 Spring 2008 Dr. Mohammad Zainal Measures of central tendency for ungrouped data


slide-1
SLIDE 1

DEPARTMENT OF QUANTITATIVE METHODS & INFORMATION SYSTEMS

Introduction to Business Statistics Introduction to Business Statistics QM 120 Ch t 3 Chapter 3

  • Dr. Mohammad Zainal

Spring 2008

slide-2
SLIDE 2

Measures of central tendency for ungrouped data

2

Graphs are very helpful to describe the basic shape of a data

distribution; “a picture is worth a thousand words.” There are

2

distribution; a picture is worth a thousand words. There are limitations, however to the use of graphs.

One way to overcome graph problems is to use numerical One way to overcome graph problems is to use numerical

measures, which can be calculated for either a sample or a population. population.

Numerical descriptive measures associated with a population

  • f measurements are called parameters; those computed from
  • f measurements are called parameters; those computed from

sample measurements are called statistics.

A measure of central tendency gives the center of a histogram A measure of central tendency gives the center of a histogram

  • r frequency distribution curve.

Th di d d

The measures are: mean, median, and mode.

QM-120, M. Zainal

slide-3
SLIDE 3

Measures of central tendency for ungrouped data

3

Data that give information on each member of the population

  • r sample individually are called ungrouped data, whereas

3

  • r sample individually are called ungrouped data, whereas

grouped data are presented in the form of a frequency distribution table.

Mean

The mean (average) is the most frequently used measure of

( g ) q y central tendency.

The mean for ungrouped data is obtained by dividing the sum

e ea

  • u g ouped data is obtai ed by di idi g t e su
  • f all values by the number if values in the data set. Thus,

x

x x N x

∑ ∑

= = : sample for Mean : population for Mean μ n x = : sample for Mean

QM-120, M. Zainal

slide-4
SLIDE 4

Measures of central tendency for ungrouped data

4

Example: The following table gives the 2002 total payrolls of five MLB teams.

4

2002 total payroll (millions of dollars) MLB team 62 Anaheim Angels 93 Atlanta Braves 126 New York Yankees 126 New York Yankees 75

  • St. Louis Cardinals

34 Tampa Bay Devil Rays

The Mean is a balancing point

34 62 93 75 126

QM-120, M. Zainal

slide-5
SLIDE 5

Measures of central tendency for ungrouped data

5

Sometimes a data set may contain a few very small or a few

very large values. Such values are called outliers or extreme

5

very large values. Such values are called outliers or extreme values.

We should be very cautious when using the mean It may not We should be very cautious when using the mean. It may not

always be the best measure of central tendency. Example: The following table lists the 2000 populations (in Example: The following table lists the 2000 populations (in thousands) of five Pacific states.

Excluding California 5894 Washington Population (thousands) State

5 . 2788 4 1212 627 3421 5894 Mean = + + + =

1212 Hawaii 627 Alaska 3421 Oregon An

  • utlier

2 . 9005 5 33,872 1212 627 3421 5894 Mean = + + + + =

Including California California 33,872

5

QM-120, M. Zainal

slide-6
SLIDE 6

Measures of central tendency for ungrouped data

6

Weighted Mean

Sometimes we may assign weight (importance) to each

6

Sometimes we may assign weight (importance) to each

  • bservation before we calculate the mean.

A mean computed in this manner is refereed to as a weighted

mean and it is given by g y

∑ ∑

=

i i i

W x W x

where xi is the value of observation i and Wi is weight for

  • bser ation i

i

  • bservation i.

QM-120, M. Zainal

slide-7
SLIDE 7

Measures of central tendency for ungrouped data

7

Example: Consider the following sample of four purchases of

  • ne stock in the KSE Find the average cost of the stock

7

  • ne stock in the KSE. Find the average cost of the stock.

Purchase Price Quantity 1 300 5 000 1 .300 5,000 2 .325 15,000 3 .350 10,000 4 .295 20,000

QM-120, M. Zainal

slide-8
SLIDE 8

Measures of central tendency for ungrouped data

8

Median

The median is the value of the middle term in a data set has

8

set data ranked a in term 2 1 n the

  • f

Value Median

th

⎟ ⎠ ⎞ ⎜ ⎝ ⎛ + =

been ranked in increasing order.

2 ⎠ ⎝

The value .5(n + 1) indicates the position in the ordered data

set.

If n is even, we choose a value halfway between the two

middle observations Example: Find the median for the following two sets of measurements 2, 9, 11, 5, 6 2, 9, 11, 5, 6, 27

QM-120, M. Zainal

slide-9
SLIDE 9

Measures of central tendency for ungrouped data

9

Mode

The mode is the value that occurs with the highest frequency

9

g q y in a data set.

A data with each value occurring only once has no mode. A data with each value occurring only once has no mode. A data set with only one value occurring with highest

frequency has only one mode it is said to be unimodal frequency has only one mode, it is said to be unimodal.

A data set with two values that occurs with the same (highest)

frequency has two modes it is said to be bimodal frequency has two modes, it is said to be bimodal.

If more than two values in a data set occur with the same

(hi h t) f it i id t b lti d l (highest) frequency, it is said to be multimodal.

QM-120, M. Zainal

slide-10
SLIDE 10

Measures of central tendency for ungrouped data

10

Example: You are given 8 measurements: 3, 5, 4, 6, 12, 5, 6, 7. Find

10

a) The mean. b) The median. c) The mode. Relationships among the mean, median, and Mode p g

Symmetric histograms when

Mean = Median = Mode Mean Median Mode

Right skewed histograms when

Mean > Median > Mode Mean > Median > Mode

Left skewed histograms when

d d Mean < Median < Mode

QM-120, M. Zainal

slide-11
SLIDE 11

Measures of dispersion for ungrouped data

11

Range

Data sets may have same center but look different because of

11

y the way the numbers are spread out from center. Example:

Company 1: 47 38 35 40 36 45 39 Company 2: 70 33 18 52 27

Measure of variability can help us to create a mental picture of

the spread of the data.

The range for ungrouped data

Range = Largest value – Smallest value

The range, like the mean, is highly influenced by outliers. The range is based on two values only.

g y

QM-120, M. Zainal

slide-12
SLIDE 12

Measures of dispersion for ungrouped data

12

Variance and standard deviation

The standard deviation is the most used measure of dispersion.

12

p It tells us how closely the values of a data set are clustered around the mean.

In general, larger values of standard deviation indicate that

values of that data set are spread over a relatively larger range p y g g around the mean and vice versa.

( ) ( )

2 2 2 2

∑ ∑ ∑ ∑

x x

( ) ( )

1 : sample and , : Population

2 2 2 2

− − = − =

∑ ∑ ∑ ∑

n n x x s N N x x σ

Standard deviation is always non‐negative

2 2

and s s = = σ σ

Standard deviation is always non negative

QM-120, M. Zainal

slide-13
SLIDE 13

Measures of dispersion for ungrouped data

13

Example: Find the standard deviation of the data set in table.

13

2002 payroll (millions of dollars) MLB team 62 A h i A l 62 Anaheim Angels 93 Atlanta Braves 126 New York Yankees 75

  • St. Louis Cardinals

34 Tampa Bay Devil Rays QM-120, M. Zainal

slide-14
SLIDE 14

Measures of dispersion for ungrouped data

14

In some situations we may be interested in a descriptive

statistics that indicates how large is the standard deviation

14

statistics that indicates how large is the standard deviation compared to the mean.

It is very useful when comparing two different samples with It is very useful when comparing two different samples with

different means and standard deviations.

It is given by: It is given by:

⎞ ⎛σ % 100⎟ ⎟ ⎠ ⎞ ⎜ ⎜ ⎝ ⎛ × = μ σ CV

QM-120, M. Zainal

slide-15
SLIDE 15

Mean, variance, and standard deviation for grouped data

15

Mean for grouped data

Once we group the data, we no longer know the values of

15

g p , g individual observations.

Thus, we find an approximation for the sum of these values. Thus, we find an approximation for the sum of these values.

l ti f M mf

: sample for Mean : population for Mean mf x N f

∑ ∑

= = μ class. a

  • f

frequency the is and midpoint the is Where : sample for Mean f m n x

QM-120, M. Zainal

slide-16
SLIDE 16

Mean, variance, and standard deviation for grouped data

16

Variance and standard deviation for grouped data

16

( )

2 2

mf f m − ∑

( )

: Population

2 2 2

mf N N f =

∑ ∑ ∑

σ

( )

1 : Sample

2 2

n n mf f m s − − =

∑ ∑

class. a

  • f

frequency the is and midpoint the is Where f m

2 2

and s s = = σ σ

QM-120, M. Zainal

slide-17
SLIDE 17

Mean, variance, and standard deviation for grouped data

17

Example: The table below gives the frequency distribution of

the daily commuting times (in minutes) from home to CBA for

17

all 25 students in QMIS 120. Calculate the mean and the standard deviation of the daily commuting times.

f Daily commuting time (min) 4 0 to less than 10 9 10 to less than 20 9 10 to less than 20 6 20 to less than 30 4 30 to less than 40 2 40 to less than 50

25 Total

QM-120, M. Zainal

slide-18
SLIDE 18

Use of standard deviation

18

Z‐Scores

We often are interested in the relative location of a data point xi

18

We often are interested in the relative location of a data point xi

with respect to the mean (how far or how close).

The z‐scores (standardized value) can be used to find the The z scores (standardized value) can be used to find the

relative location of a data point xi compared to the center of the data. data.

It is given by

s x x Z

i i

− =

The z‐score can be interpreted as the number of standard

deviations xi is from the mean.

QM-120, M. Zainal

slide-19
SLIDE 19

Use of standard deviation

19

Example: Find the z‐scores for the following data where the mean is 44 and the standard deviation is 8.

19

mean is 44 and the standard deviation is 8.

Number of students in a class 46 54 42 46 32

QM-120, M. Zainal

slide-20
SLIDE 20

Use of standard deviation

20

Chebyshevʹs Theorem

Chebyshevʹs theorem allows you to understand how the value

20

y y

  • f a standard deviation can be applied to any data set.

Chebyshevʹs theorem: The fraction of any data set lying within Chebyshev s theorem: The fraction of any data set lying within

k standard deviations of the mean is at least 1 where k = a number greater than 1.

2

1 1 k − where k a number greater than 1.

This theorem applies to all data sets, which include a sample or

a population a population.

Chebyshev’s theorem is very conservative but it can be applied

to a data set with any shape to a data set with any shape.

QM-120, M. Zainal

slide-21
SLIDE 21

Use of standard deviation

21 21

k = 1 k = 2 k = 3

QM-120, M. Zainal

slide-22
SLIDE 22

Use of standard deviation

22

Example: The average systolic blood pressure for 4000 women who were screened for high blood pressure was found to be 187

22

who were screened for high blood pressure was found to be 187 with standard deviation of 22. Using Chebyshev’s theorem, find at least what percentage of women in this group have a systolic p g g p y blood pressure between 143 and 231.

QM-120, M. Zainal

slide-23
SLIDE 23

Use of standard deviation

23

Empirical Rule

The empirical rule gives more precise information about a data

23

set than the Chebyshevʹs Theorem, however it only applies to a data set that is bell‐shaped. Th

Theorem:

1‐ 68% of the observations lie within one standard deviation of the mean. 2 95% of the observations lie within two standard deviations of the mean 2‐ 95% of the observations lie within two standard deviations of the mean. 3‐ 99.7% of the observations lie within three standard deviations of the mean.

QM-120, M. Zainal

slide-24
SLIDE 24

Use of standard deviation

24

Example: The age distribution of a sample of 5000 persons is bell‐shaped with a mean of 40 years and a standard deviation of

24

12 years. Determine the approximate percentage of people who are 16 to 64 years old.

QM-120, M. Zainal

slide-25
SLIDE 25

Use of standard deviation

25

Detecting outliers

Sometimes a data set may have one or more observation that is

25

Sometimes a data set may have one or more observation that is

unusually small or large value.

This extreme value is called an outlier and cam be detected This extreme value is called an outlier and cam be detected

using the z‐score and the empirical rule for data with bell‐shape distribution distribution.

An experienced statistician may face the following situations

d d t t k ti and need to take an action

Outlier Action A data value that was incorrectly recorded Correct it before any further analysis A data value that was incorrectly recorded Correct it before any further analysis A data value that was incorrectly included Remove it before any further analysis A data value that belongs to the data set and Keep it ! correctly recorded

QM-120, M. Zainal

slide-26
SLIDE 26

Measure of position

26

Quartiles and interquartile range

A measure of position which determines the rank of a single

26

A measure of position which determines the rank of a single

value in relation to other values in a sample or population.

Quartiles are three measures that divide a ranked data set into Quartiles are three measures that divide a ranked data set into

four equal parts

QM-120, M. Zainal

slide-27
SLIDE 27

Measure of position

27

Calculating the quartiles

The second quartile is the median of a data set.

27

q

The first quartile, Q1, is the value of the middle term among

  • bservations that are less than the median.
  • bse

a io s a a e ess a e e ia

The third quartile, Q3, is the value of the middle term among

  • bservations that are greater than the median.
  • bservations that are greater than the median.

Interquartile range (IQR) is the difference between the third Interquartile range (IQR) is the difference between the third

quartile and the first quartile for a data set. IQR = Interquartile range = Q3 – Q1 Q q g Q3 Q1

QM-120, M. Zainal

slide-28
SLIDE 28

Measure of position

28

Example: For the following data

75.3 82.2 85.8 88.7 94.1 102.1 79.0 97.1 104.2 119.3 81.3 77.1

28

Find

The values of the three quartiles The values of the three quartiles. The interquartile range. Where does the 104 2 fall in relation to these quartiles Where does the 104.2 fall in relation to these quartiles. QM-120, M. Zainal

slide-29
SLIDE 29

Measure of position

29

Percentile and percentile rank

Percentiles are the summery measures that divide a ranked

29

Percentiles are the summery measures that divide a ranked

data set into 100 equal parts.

The kth percentile is denoted by Pk where k is an integer in the The k

percentile is denoted by Pk , where k is an integer in the range 1 to 99.

The approximate value of the kth percentile is

set data ranked a in term 100 the

  • f

Value

th k

kn P ⎟ ⎠ ⎞ ⎜ ⎝ ⎛ =

QM-120, M. Zainal

slide-30
SLIDE 30

Measure of position

30

Example: For the following data

75 3 82 2 85 8 88 7 94 1 102 1 79 0 97 1 104 2 119 3 81 3 77 1

30

75.3 82.2 85.8 88.7 94.1 102.1 79.0 97.1 104.2 119.3 81.3 77.1

Find the value of the 40th percentile. Solution:

QM-120, M. Zainal

slide-31
SLIDE 31

Box-and-whisker plot

31

Box and whisker plot gives a graphic presentation of data

using five measures:

31

g

Q1, Q2, Q3, smallest, and largest values*.

Can help to visualize the center, the spread, and the skewness Can help to visualize the center, the spread, and the skewness

  • f a data set.

Can help in detecting outliers.

a e p i e e i g ou ie

Very good tool of comparing more than a distribution. Detecting an outlier: Detecting an outlier:

Lower fence: Q1 – 1.5(IQR) Upper fence: Q + 1 5(IQR) Upper fence: Q3 + 1.5(IQR) If a data point is larger than the upper fence or smaller than the

lower fence, it is considered to be an outlier. lower fence, it is considered to be an outlier.

QM-120, M. Zainal

slide-32
SLIDE 32

Box-and-whisker plot

32

To construct a box plot

Draw a horizontal line representing the scale of the measurements. 32 Calculate the median, the upper and lower quartiles, and the IQR for the

data set and mark them on the line. Form a box just above the line with the right and left ends at Q1 and Q3

Form a box just above the line with the right and left ends at Q1 and Q3. Draw a vertical line through the box at the location of the median. Mark any outliers with an asterisk (*) on the graph Mark any outliers with an asterisk ( ) on the graph. Extend horizontal lines called “Whiskers” from the ends of the box to the

smallest and largest observation that are not outliers.

Q1 Q2 Q3 Lower Upper

* *

Q1 Q2 Q3 fence pp fence

QM-120, M. Zainal

slide-33
SLIDE 33

Box-and-whisker plot

33

Example: Construct a box plot for the following data. 340 300 470 340 320 290 260 330

33

340 300 470 340 320 290 260 330

QM-120, M. Zainal

slide-34
SLIDE 34

Measures of association between two variables

34

So far we have studied numerical methods to describe data

with one variable.

34

Often decision makers are interested in the relationship

between two variables.

To do so, we will use descriptive measure that is called

covariance.

Covariance assigns a numerical value to the linear relationship

between two variables (see scatter diagram). It is given by ( )( )

n y y x x

i i

− − − = ∑

xy

1 S : covariance Sample

( )(

)

N y x n

y i x i

μ μ σ − − = ∑

xy

: covariance Population 1

QM-120, M. Zainal

slide-35
SLIDE 35

Measures of association between two variables

35

A big disadvantage of the covariance is that it depends on the

units of measurement for x and y.

35

y

For the same data set, we will have two different covariance

values depending on the units (i.e. height in meters or p g ( g centimeters will make a big difference).

Pearson’s correlation coefficient is a good remedy to that problem

ff g y p as it can go only from ‐1 to 1.

It is given by

: t coefficien n correlatio Population

xy

= σ σ , S S S r : t coefficien n correlatio Sample : t coefficien n correlatio Population

xy xy y x xy

= σ σ σ S S

y x y

QM-120, M. Zainal

slide-36
SLIDE 36

Measures of association between two variables

36

Example: A golfer is interested in investigating the relationship, if any, between driving distance and 18‐hole score.

36

y, g

Average Driving Distance (meters) Average 18‐Hole Score 277.6 259.5 269 1 69 71 70 269.1 267.0 255.6 70 70 71 272.9 69

QM-120, M. Zainal

slide-37
SLIDE 37

Measures of association between two variables

37

x y

37

277.6 259 5 69 71 259.5 269.1 267.0 255 6 71 70 70 71 255.6 272.9 71 69

QM-120, M. Zainal

slide-38
SLIDE 38

Measures of association between two variables

38

Example: Find the covariance and Pearson’s correlation coefficient for the following data

38

Week Number of commercials (x) Sales in $ (y) 1 2 50 2 5 57 2 5 57 3 1 41 4 3 54 5 4 54 6 1 38 7 5 63 8 3 48 9 4 59 10 2 46 10 2 46

QM-120, M. Zainal