Measures of Central Tendency: The following are the five measures of central tendency that are in common use: i. ii. iii. iv. v. Arithmetic mean or simple mean Median Mode Geometric mean Harmonic mean Arithmetic Mean: Arithmetic mean of a set of observations is their sum divided by number of observations, for example, the arithmetic mean ๐ฅฬ of n observations ๐ฅ 1, ๐ฅ 2 , ๐ฅ 3 , … , ๐ฅ ๐ is given by: ๐ ๐ ๐ ฬ = (๐๐ +๐๐ + ๐๐ + โฏ + ๐๐) = ∑ ๐๐ ๐ ๐ ๐ ๐=๐ In case the frequency distribution ๐๐ , ๐ = 1,2,3, … , ๐, where ๐๐ is the frequency of the variable ๐ฅ๐ , ๐ฅฬ = ๐1๐ฅ 1+๐2๐ฅ 2+๐3๐ฅ 3+โฏ+๐๐๐ฅ ๐ ๐1+๐2+๐2+โฏ+๐๐ 1 = ∑๐๐=1 ๐๐ ๐ฅ๐, where ๐ = ∑๐๐=1 ๐๐ ๐ In case of grouped or continuous frequency distribution, x is taken as the as the mid value of the corresponding class. It may be noted that if the values of x or f are large, the calculation of mean by formula is 1 ๐ ∑๐ =1 ๐๐ ๐ฅ๐ is quite time-consuming and tedious. The arithmetic is reduced to a great extent ๐ by taking the deviations of the given values from any arbitrary point ‘A’ as explained below: Let ๐๐ = ๐ฅ ๐ − ๐ด. Then ๐๐ ๐๐ = ๐๐ (๐ฅ ๐ − ๐ด) = ๐๐ ๐ฅ๐ − ๐ด๐๐ Summing both sides over ๐ from 1 to n, we get ๐ ๐ ๐ ๐=1 ๐=1 ๐=1 ๐ ∑ ๐๐ ๐๐ = ∑ ๐๐ ๐ฅ๐ − ๐ด ∑๐๐ = ∑ ๐๐ ๐ฅ๐ − ๐ด๐ ๐ ๐ ๐ ๐=1 ๐ 1 1 1 1 ∑ ๐๐ ๐๐ = ∑ ๐๐ ๐ฅ๐ − ๐ด ∑๐๐ = ∑๐๐ ๐ฅ ๐ − ๐ด ๐ ๐ ๐ ๐ ๐=1 ๐=1 ๐=1 ๐=1 ๐ 1 ∑ ๐๐ ๐๐ = ๐ฅฬ − ๐ด ๐ ๐=1 Where ๐ฅฬ is the arithmetic mean of the distribution. ๐ 1 ๐ฅฬ = ๐ด + ∑ ๐๐ ๐๐ ๐ ๐=1 In case of grouped (or) continuous frequency distribution, the arithmetic is reduced to still greater extent by taking point h is the common magnitude of class interval. In this case, we have h๐๐ = ๐ฅ ๐ − ๐ด and proceeding exactly similarly above, we get ๐ h ๐ฅฬ = ๐ด + ∑ ๐๐ ๐๐ ๐ ๐=1 Problem 1: The intelligence quotient (IQ’s) of 10 boys in a class are given below: 70, 120, 110, 101, 88, 83, 95, 98, 107, 100. Then find the mean I.Q. Solution: Mean I.Q of 10 boys in a class are given below: ∑ ๐ 70+120+ 110+ 101+ 88+ 83+ 95+ 98+ 107+ 100 972 ๐ฬ = = = = 97.2 ๐ 10 10 Problem 2: The following frequency is distribution of the number of telephone calls received in 245 successive one-minute intervals at an exchange: No. of calls 0 1 2 3 4 5 6 7 frequency 14 21 25 43 51 40 39 12 Obtain the mean number of calls per minute. Solution: No. of Calls (๐) 0 Frequency (๐) 14 ๐๐ 1 21 21 2 25 50 3 43 129 4 51 204 5 40 200 6 39 234 7 12 84 ๐ = 245 ∑ ๐๐ = 922 0 Mean number of calls per minute at the at the exchange is given by ๐ฬ = ∑ ๐๐ 922 = = 3.763 245 ๐ Problem 3: Find the arithmetic mean of the following frequency distribution: ๐ ๐ 1 2 3 4 5 6 7 5 9 12 17 14 10 6 Solution: ๐ ๐ ๐๐ 1 5 5 2 9 18 3 12 36 4 17 68 5 14 70 6 10 60 7 7 42 Total 73 299 7 1 299 ๐ฅฬ = ∑ ๐๐ ๐ฅ๐ = = 4.09 ๐ 73 ๐=1 Problem 4: For a certain frequency table which has only been partly reproduced here, the mean was found to be 1.46. 0 1 2 3 4 5 Total 46 ? ? 25 10 5 200 Calculate the missing frequencies. Solution: Let ๐ denote the number of accidents and let the missing frequencies corresponding to ๐ = 1 and ๐ = 2 be ๐1 ๐๐๐ ๐2 respectively. No. of accidents (๐) Frequency (๐) 0 46 ๐๐ 1 2 ๐1 ๐1 3 25 ๐2 0 2๐2 75 4 10 40 5 5 25 86 + ๐1 + ๐2 = 200 140 + ๐1 + 2๐2 200 = 86 + ๐1 + ๐2 ๐1 + ๐2 = 200 − 86 = 114 ๐ฬ = ๐1 + ๐2 = 114 (1) ๐1 + 2๐2 + 140 1 ∑ ๐๐ = = 1.46 200 ๐ ๐1 + 2๐2 + 140 = 1.46 × 200 = 292 ๐1 + 2๐2 = 292 − 140 = 152 ๐1 + 2๐2 = 152 (2) Solving equations (1) and (2), we get ๐1 = 38, ๐2 = 76 Problem 5: Calculate the arithmetic mean of the marks from the following table: Marks 0-10 10-20 20-30 30-40 40-50 50-60 No. of Students 12 18 27 20 17 6 Solution: Marks No. of Students Mid-point (๐) 0-10 12 5 60 (๐) (๐) 10-20 18 15 270 20-30 27 25 675 30-40 20 35 700 40-50 17 45 765 50-60 6 55 330 Total 100 2800 ๐ด๐๐๐กh๐๐๐ก๐๐ ๐๐๐๐ = ๐ฅฬ = 1 1 ∑ ๐๐ฅ = × 2800 = 28 100 ๐ Problem 6: Calculate the mean for the following frequency distribution: Class interval 0-8 8-16 16-24 24-32 32-40 40-48 Frequency 8 7 16 24 15 7 ๐= Solution: Here we take ๐ด = 28, h = 8 ๐ฅ −๐ด h (๐๐) -3 -24 7 -2 -14 20 16 -1 -16 24-32 28 24 0 0 32-40 36 15 1 15 40-48 44 7 2 14 Class interval Mid-value Frequency 0-8 (๐ฅ) 4 (๐) 8 8-16 12 16-24 Total 77 -25 = 28 + ๐ฅฬ = ๐ด + h ∑ ๐๐ ๐ 8 × (−25) 20 = 28 − = 25.404 77 77 Problem 7: Try this? Calculate the mean for the following frequency distribution: Marks 0-10 10-20 20-30 30-40 40-50 50-60 60-70 Number of students 6 5 8 15 7 6 3 Median: Median of a distribution is the value of the variable which divides it into two equal parts. It is the value which exceeds and is exceeded by the same number of observations. That is, it is the value such that the number of observations above it is equal to the number of observations below it. The median is thus a positional average. In case of ungrouped data, if the number of observations is odd then median is the middle value after the values have been arranged in ascending or descending order of magnitude. In case of even number of observations, there are two middle terms are median is obtained by taking the arithmetic mean of the middle terms. For example, the median of the values 8,4,7,6,2, i.e., 2,4,6,7,8 is 6 and the median of 10,15,30,70,40,80, i.e., 10,15,30,40,70,80 is 1 2 (30 + 40) = 35. In case of discrete frequency distribution median is obtained by considering the cumulative frequencies. The steps for calculating median are given below: ๏ง ๐ Find 2 , where ๐ = ∑๐๐=1 ๐๐ ๏ง ๏ง ๐ See the (less than) cumulative frequency (c.f.) just greater than 2 . The corresponding value of ๐ฅ is median. Example 1: Obtain the median for the following frequency distribution: ๐ฅ ๐ 1 2 3 4 5 6 7 8 9 8 10 11 16 20 25 15 9 6 Solution: ๐ฅ 1 ๐ 8 ๐. ๐. 2 10 18 3 11 29 4 16 45 5 20 65 6 25 90 7 15 105 8 9 114 9 6 120 8 ๐ = 120 ๐ = 120 ๐ = 60 2 The cumulative frequency (c.f.) just greater than to 65 is 5. So, median is 5. ๐ 2 is 65 and the value of ๐ฅ corresponding Example 2: Eight coins were tossed together and the number of heads (๐ฅ) resulting was noted. The operation was repeated 256 times and the frequency distribution of the number of heads is given below: No. of heads (๐ฅ) 0 Frequency (๐) 1 1 2 3 4 5 6 7 8 9 26 59 72 52 29 7 1 Find the median. Solution: ๐ฅ 0 ๐ 1 ๐. ๐. 1 9 10 2 26 36 3 59 95 4 72 167 5 52 219 6 29 248 7 7 255 8 1 256 ๐ =256 1 ๐ = 256 ๐ = 128 2 The cumulative frequency (c.f.) just greater than to 167 is 5. So, median is 4. ๐ 2 is 128 and the value of ๐ฅ corresponding Derivation of Median: Median for Continuous frequency distribution: In the case of continuous frequency distribution, the class corresponding to the c.f. just ๐ greater than 2 is called the median class and the value of median is obtained by the following formula: h ๐ ๐๐๐๐๐๐ = ๐ + ( − ๐) ๐ 2 Where ๐ is the lower limit of the median class ๐ is the frequency of the median class h is the magnitude of the median class ๐ is the c.f. of the class preceding the median class ๐ = ∑๐ Example 1: Find the median wage of the following distribution: Wages (in rupees) No. of workers 2000-3000 3 3000-4000 5 4000-5000 20 5000-6000 10 6000-7000 5 Solution: Now we have to write the given distribution into continuous frequency distribution. No. of workers (๐) ๐. ๐. 3 3 3000-4000 5 8 4000-5000 20 28 5000-6000 10 38 6000-7000 5 43 Wages (in rupees) 2000-3000 ๐ = 43 ๐ = 43 ๐ = 21.5 2 Cumulative frequency is just greater than 21.5 is 28 and the corresponding class is 40005000. Median class is 4000-5000. h ๐ ๐๐๐๐๐๐ = ๐ + ( − ๐) ๐ 2 ๐๐ = 4000 + 1000 43 20 ๐ = 4000, h = 1000, ๐ = 20, ๐ = 43, ๐ = 8 ( − 8) = 4675 rupees. 2 The median wage is 4675 rupees. Example 2: Find the frequency distribution of weight in grams of mangoes of a given variety is given below. Then find the median. Weight in grams 410-419 420-429 430-439 440-449 450-459 460-469 470479 No. of mangoes 14 20 54 45 7 42 18 Solution: Continuous frequency distribution we have to convert the given inclusive class interval series into exclusive class interval series 409.5-419.5 No. of mangoes (๐) 14 ๐. ๐. (Less than) 419.5-429.5 20 34 429.5-439.5 42 76 439.5-449.5 54 130 449.5-459.5 45 175 459.5-469.5 18 193 469.5-479.5 7 200 Weight in grams 14 ๐ = 200 ๐ = 200 ๐ = 100 2 The c.f. just greater than 100 is 130 So, the corresponding class 439.5-449.5 is the median class. Now we have to find the median for continuous data h ๐ ๐๐๐๐๐๐ = ๐ + ( − ๐) ๐ 2 = 439.5 + 10 200 54 ( 2 ๐ = 439.5, h = 10, ๐ = 54, ๐ = 200, ๐ = 76 − 76) = 443.94 gms. Example 3: Find the missing frequency from the following distribution of daily sales of shops, given that the median sale of shops in Rs. 2,400. Sales (in hundred rupees) 0-10 10-20 20-30 30-40 40-50 No. of shops 5 25 ? 8 7 Solution: Let the frequency be ๐ฅ. Given that the median sale of shops is 24 hundred. Sales (in hundred rupees) No. of shops(๐) 0-10 5 ๐. ๐. 10-20 25 30 20-30 30-40 18 40-50 7 5 ๐ฅ ๐ = 55 + ๐ฅ 30 + ๐ฅ 48 + ๐ฅ 55 + ๐ฅ h ๐ ๐๐๐๐๐๐ = ๐ + ( − ๐) ๐ 2 ๐ = 20, h = 10, ๐ = ๐ฅ, ๐ = 55 + ๐ฅ, ๐ = 30 24 = 20 + 10 55 + ๐ฅ ( − 30) ๐ฅ 2 ๐ฅ = 25 Example 4: In the frequency distribution of 100 families given below, the number of families corresponding to expenditure groups 20-40 and 60-80 are missing from table. However, the median is known to be 50. Find the missing frequencies. Expenditure 0-20 20-40 40-60 60-80 80-100 No. of families 14 ? 27 ? 15 Solution: Let the missing frequencies for the classes 20-40 and 60-80 be ๐1 ๐๐๐ ๐2 respectively. Expenditure (in rupees) 0-20 No. of families (๐) 14 27 14 + ๐1 15 ๐2 41 + ๐1 + ๐2 60-80 80-100 14 ๐1 20-40 40-60 ๐. ๐. ๐ = 56 + ๐1 + ๐2 41 + ๐1 56 + ๐1 + ๐2 The no. of families is 100, therefore ๐ = 100 = 56 + ๐1 + ๐2 ๐1 + ๐2 = 44 Given that median is 50, which lies class 40-60. therefore, 40-60 is the median class. ๐ = 40, h = 20, ๐ = 27, ๐ = 56 + ๐1 + ๐2 , ๐ = 14 + ๐1 h ๐ ๐๐๐๐๐๐ = ๐ + ( − ๐) ๐ 2 50 = 40 + 20 100 ( − (14 + ๐1 )) 27 2 10 = 20 (36 − ๐1 ) 27 ๐1 = 22.5 ≈ 23 ๐2 = 21 Try these: 1. Calculate the mean and median from the following distribution Class 10-20 20-30 30-40 40-50 50-60 60-70 70-80 80-90 Frequency 4 12 40 41 27 13 9 4 2. A number of particular articles has been classified according to their weights. After drying two weeks the same articles have again been weighted and similarly classified. It is known that the median weight in the first weighing is 20.83 gm, while in the second weighing it was 17.35 gm. Some frequencies ๐ ๐๐๐ ๐ in the first weighing and ๐ฅ ๐๐๐ ๐ฆ 1 1 in the second are missing. It is known that ๐ = 3 ๐ฅ ๐๐๐ ๐ = 2 ๐ฆ . Find out the values of the missing frequencies. Geometric Mean: The geometric mean, usually abbreviated as G.M. of a set of ๐ observations is the ๐๐กh root of their product. Thus, if ๐1 , ๐2 , ๐3 , … , ๐๐ are the ๐ observations then their G.M. is given by ๐ 1 ๐บ. ๐ = √ ๐1 × ๐2 × ๐3 × … × ๐๐ = (๐1 × ๐2 × ๐3 × … × ๐๐ )๐ If ๐ = 2 i.e., if we take two observations, then ๐บ. ๐ = √๐1 × ๐2 (1) If ๐ number of observations, then the ๐๐กh root is very tedious. In such a case the calculations by making use of the logarithms. Now take logarithm both sides of eq. (1), we get 1 log(๐บ. ๐) =log(๐1 × ๐2 × ๐3 × … × ๐๐ )๐ 1 = log(๐1 × ๐2 × ๐3 × … × ๐๐) ๐ 1 = (log๐1 + ๐๐๐๐2 + ๐๐๐๐3 + … + ๐๐๐ ๐๐ ) ๐ 1 log(๐บ. ๐) = ∑ ๐๐๐๐ (2) ๐ i.e., the logarithm of the G.M of a set of observations is the arithmetic mean of their logarithms. Now, taking Antilog on both sides of eq. (2) 1 ๐บ. ๐ = ๐ด๐๐ก๐๐๐๐ ( ∑ ๐๐๐๐) ๐ In case of frequency distribution (๐๐ , ๐๐ ), ๐ = 1,2,3, … , ๐ , where the total no. of observations is ๐ = ∑ ๐. [(๐1 × ๐1 × ๐1 × … × ๐1 ๐ก๐๐๐๐ ) × (๐2 × ๐2 × ๐2 × … × ๐2 ๐ก๐๐๐๐ ) × … × 1 ๐ (๐n × ๐n × ๐n × … × ๐๐ ๐ก๐๐๐๐ )] 1 ๐บ. ๐ = (๐1 × ๐2 × ๐3 × … × ๐๐ ) ๐ Taking logarithm on both sides of eq. (3) 1 log(๐บ. ๐) = [๐๐๐(๐1 ๐1 × ๐2 ๐2 × … × ๐๐ ๐๐ )] ๐ 1 = [๐๐๐๐1 ๐1 + ๐๐๐๐2 ๐2 + โฏ + ๐๐๐๐๐ ๐๐ ] ๐ 1 = [๐1 ๐๐๐๐1 + ๐2 ๐๐๐๐2 + โฏ + ๐๐ ๐๐๐๐๐ ] ๐ 1 log(๐บ. ๐) = ∑๐ ๐๐๐๐ ๐ 1 ๐บ. ๐ = ๐ด๐๐ก๐๐๐๐ [ ∑ ๐ ๐๐๐๐] ๐ (3) Example 1: Find the geometric mean of 2,4,8,12,16 and 24. Solution: ๐๐๐๐ ๐ 2 0.3010 4 0.6021 8 0.9031 12 1.0792 16 1.2041 24 1.3802 ∑ ๐๐๐๐ = 5.4697 1 log(๐บ. ๐) = ∑ ๐๐๐๐ ๐ 1 = (5.4697) = 0.9116 6 = ๐ด๐๐ก๐๐๐๐(0.9116) = 8.158 ๐บ. ๐ = 8.158 Example 2: Find the geometric mean for the following distribution: Marks 0-10 10-20 20-30 30-40 40-50 No. of students 5 7 15 25 8 Solution: 0-10 Mid-point (๐) 5 No. of students(๐) 5 ๐๐๐๐ 0.6990 3.4950 10-20 15 7 1.1761 8.2327 20-30 25 15 1.3979 20.9685 30-40 35 25 1.5441 38.6025 40-50 45 8 1.6532 13.2256 Marks ๐ = 60 ๐ ๐๐๐๐ ∑ ๐ ๐๐๐๐ = 84.5243 1 ๐บ. ๐ = ๐ด๐๐ก๐๐๐๐ [ ∑ ๐ ๐๐๐๐] ๐ = ๐ด๐๐ก๐๐๐๐ [ 1 (84.5243)] 60 = ๐ด๐๐ก๐๐๐๐(1.4087) = 25.64 marks Example 3: The geometric mean of 10 observations on a certain variable was calculated as 16.2. It was later discovered that one of the observations was wrongly recorded as 12.9; in fact, it was 2.19. Apply approximate correction and calculate the correct geometric mean. Solution: Geometric mean of observations is given by ๐บ = (๐1 × ๐2 × ๐3 × … × ๐๐ ) 1 ๐ (1) ๐บ ๐ = ๐1 × ๐2 × ๐3 × … × ๐๐ The product of the numbers is given by ๐1 × ๐2 × ๐3 × … × ๐๐ = ๐บ ๐ = (16.20)10 (2) If the wrong observation 12.9 is replaced by the correct values 21.9, then the corrected value of the product of 10 numbers is obtained on dividing the expression in (2) by wrong observation and multiplying by the product of correct observation. Thus, the corrected product (๐1 × ๐2 × ๐3 × … × ๐๐ ) = The corrected value of G.M, is say ๐บ ′ (16.20) 10 × 21.9 12.9 1 (16.20) 10 × 21.9 10 ] ๐บ′ = [ 12.9 1 (16.20) 10 × 21.9 10 ] ๐๐๐๐บ ′ = ๐๐๐ [ 12.9 1 [[๐๐๐(16.20) 10 + ๐๐๐(21.9) − ๐๐๐(12.9)]] 10 1 [10 ๐๐๐(16.20) + ๐๐๐(21.9) − ๐๐๐(12.9)] = 10 = ๐๐๐๐บ ′ = ๐๐๐๐บ ′ = 1 [10 (1.2095) + 1.3404 − 1.1106] 10 1 [10 (1.2095) + 1.3404 − 1.1106] = 1.2325 10 ๐๐๐๐บ ′ = 1.2325 ๐บ ′ = ๐ด๐๐ก๐๐๐๐(1.2325) = 17.08 Harmonic Mean: If ๐1 , ๐2 , ๐3 , … , ๐๐ is a given ๐ set of observations, then their harmonic mean, abbreviated as H.M. 1 ๐ป=1 1 1 1 1 [ + + +โฏ+ ] ๐๐ ๐ ๐1 ๐2 ๐3 ๐ป=1 ๐ (Or) 1 1 ∑( ) ๐ Harmonic mean is the value of the variable or the mid-value of the class (in case of grouped or continuous frequency distribution) and ๐ is the corresponding frequency of ๐. In case of frequency distribution, we have ๐๐ 1 1 ๐1 ๐2 = ( + + โฏ+ ) ๐๐ ๐ป ๐ ๐1 ๐2 ๐ป= ๐ = where, ๐ = ∑ ๐ , ∑( 1 ) ๐ 1 ๐ ∑( ) ๐ ๐ ๐= mid-value of the variable or mid-value of the class ๐= frequency of ๐ Example 1: A cyclist pedals from his house to his college at a speed of 10 kmph and back from college to his house at 15 kmph. Find the average speed. Solution: Let the distance from house to college be ๐ฅ ๐๐. ๐ฅ In going from house to college, the distance ๐ฅ ๐๐ is covered by 10 hours, while in coming from college to house, the distance covered in Total distance of 2๐ฅ ๐๐ is covered in ( ๐ฅ ๐ฅ 15 10 + hours. ๐ฅ 15 ) hours. ๐ก๐๐ก๐๐ ๐๐๐ ๐ก๐๐๐๐ ๐๐๐ฃ๐๐๐๐ ๐ก๐๐ก๐๐ ๐ก๐๐๐ ๐๐ก๐๐๐ 2๐ฅ 2๐ฅ = 12 ๐๐๐h = ๐ฅ ๐ฅ = 1 ( + ) ( + 1) 10 15 10 15 ๐ด๐ฃ๐๐๐๐๐ ๐ ๐๐๐๐ = Example 2: A vehicle when climbing up a gradient, consumes petrol at the rate of 1 liter per 8 km. While coming down it gives 12 km per liter. Find its average consumption for to and fro travel between two places situated at the two ends of a 25 km long gradient. Verify your answer? Solution: Since the consumption of petrol is different for upward and downward journeys (at a constant speed of 25 km), the appropriate average consumption for to and fro journey is given by harmonic mean of 8km and 12 km. ๐ด๐ฃ๐๐๐๐๐ ๐๐๐๐ ๐ข๐๐๐ก๐๐๐ = 48 2 1 1 = 5 = 9.6 ๐๐/๐๐๐ก๐๐ ( + ) 8 12 Example 3: In a certain office, a letter is typed by ๐ด in 4 times. The same letter is typed by ๐ต, ๐ถ, ๐๐๐ ๐ท are 5,6,10 minutes respectively. What is the average time taken in completing one letter? How many letters do you expect to be typed in one day comprising of 8 working hours? Solution: The average time taken by each of ๐ด, ๐ต, ๐ถ, ๐๐๐ ๐ท in competing one letter is the harmonic mean of 4,5,6, and 10. 4 240 4 1 1 1 1 = 15 + 12 + 1 + 6 = 43 = 5.5814 ๐๐๐/๐๐๐ก๐ก๐๐ + + + ) 4 5 6 10 ( 60 Expected no. of letters typed by each of ๐ด, ๐ต, ๐ถ, ๐๐๐ ๐ท is In a day comprising 8 hours = 8 × 60 minutes. 43 240 letters/min. 43 Total letters typed all of them ๐ด, ๐ต, ๐ถ, ๐๐๐ ๐ท = 240 × 4 × 8 × 60 = 344. Geometric Mean: The geometric mean, usually abbreviated as G.M. of a set of ๐ observations is the ๐๐กh root of their product. Thus, if ๐1 , ๐2 , ๐3 , … , ๐๐ are the ๐ observations then their G.M. is given by ๐ 1 ๐บ. ๐ = √ ๐1 × ๐2 × ๐3 × … × ๐๐ = (๐1 × ๐2 × ๐3 × … × ๐๐ )๐ (1) If ๐ = 2 i.e., if we take two observations, then ๐บ. ๐ = √๐1 × ๐2 If ๐ number of observations, then the ๐๐กh root is very tedious. In such a case the calculations by making use of the logarithms. Now take logarithm both sides of eq. (1), we get log(๐บ. ๐) =log(๐1 × ๐2 × ๐3 × … × ๐๐ ) 1 1 ๐ = log(๐1 × ๐2 × ๐3 × … × ๐๐) ๐ 1 = (log๐1 + ๐๐๐๐2 + ๐๐๐๐3 + … + ๐๐๐ ๐๐ ) ๐ 1 log(๐บ. ๐) = ∑ ๐๐๐๐ (2) ๐ i.e., the logarithm of the G.M of a set of observations is the arithmetic mean of their logarithms. Now, taking Antilog on both sides of eq. (2) 1 ๐บ. ๐ = ๐ด๐๐ก๐๐๐๐ ( ∑ ๐๐๐๐) ๐ In case of frequency distribution (๐๐ , ๐๐ ), ๐ = 1,2,3, … , ๐ , where the total no. of observations is ๐ = ∑ ๐. [(๐1 × ๐1 × ๐1 × … × ๐1 ๐ก๐๐๐๐ ) × (๐2 × ๐2 × ๐2 × … × ๐2 ๐ก๐๐๐๐ ) × … × 1 (๐n × ๐n × ๐n × … × ๐๐ ๐ก๐๐๐๐ )]๐ (3) 1 ๐บ. ๐ = (๐1 × ๐2 × ๐3 × … × ๐๐ ) ๐ Taking logarithm on both sides of eq. (3) log(๐บ. ๐) = = = 1 [๐๐๐(๐1 ๐1 × ๐2 ๐2 × … × ๐๐ ๐๐ )] ๐ 1 [๐๐๐๐1 ๐1 + ๐๐๐๐2 ๐2 + โฏ + ๐๐๐๐๐ ๐๐ ] ๐ 1 [๐ ๐๐๐๐1 + ๐2 ๐๐๐๐2 + โฏ + ๐๐ ๐๐๐๐๐ ] ๐ 1 1 log(๐บ. ๐) = ∑ ๐ ๐๐๐๐ ๐ 1 ๐บ. ๐ = ๐ด๐๐ก๐๐๐๐ [ ∑ ๐ ๐๐๐๐] ๐ Example 1: Find the geometric mean of 2,4,8,12,16 and 24. Solution: ๐๐๐๐ ๐ 2 0.3010 4 0.6021 8 0.9031 12 1.0792 16 1.2041 24 1.3802 ∑ ๐๐๐๐ = 5.4697 1 log(๐บ. ๐) = ∑ ๐๐๐๐ ๐ 1 = (5.4697) = 0.9116 6 = ๐ด๐๐ก๐๐๐๐(0.9116) = 8.158 ๐บ. ๐ = 8.158 Example 2: Find the geometric mean for the following distribution: Marks 0-10 10-20 20-30 30-40 40-50 No. of students 5 7 15 25 8 Solution: 0-10 Mid-point (๐) 5 No. of students(๐) 5 ๐๐๐๐ 0.6990 3.4950 10-20 15 7 1.1761 8.2327 20-30 25 15 1.3979 20.9685 30-40 35 25 1.5441 38.6025 40-50 45 8 1.6532 13.2256 Marks ๐ = 60 ๐ ๐๐๐๐ ∑ ๐ ๐๐๐๐ = 84.5243 1 ๐บ. ๐ = ๐ด๐๐ก๐๐๐๐ [ ∑ ๐ ๐๐๐๐] ๐ = ๐ด๐๐ก๐๐๐๐ [ 1 (84.5243)] 60 = ๐ด๐๐ก๐๐๐๐(1.4087) = 25.64 marks Example 3: The geometric mean of 10 observations on a certain variable was calculated as 16.2. It was later discovered that one of the observations was wrongly recorded as 12.9; in fact, it was 2.19. Apply approximate correction and calculate the correct geometric mean. Solution: Geometric mean of observations is given by 1 ๐บ = (๐1 × ๐2 × ๐3 × … × ๐๐ )๐ (1) ๐บ ๐ = ๐1 × ๐2 × ๐3 × … × ๐๐ The product of the numbers is given by ๐1 × ๐2 × ๐3 × … × ๐๐ = ๐บ ๐ = (16.20)10 (2) If the wrong observation 12.9 is replaced by the correct values 21.9, then the corrected value of the product of 10 numbers is obtained on dividing the expression in (2) by wrong observation and multiplying by the product of correct observation. Thus, the corrected product (๐1 × ๐2 × ๐3 × … × ๐๐ ) = The corrected value of G.M, is say ๐บ ′ (16.20) 10 × 21.9 12.9 1 (16.20) 10 × 21.9 10 ] ๐บ′ = [ 12.9 = = 1 (16.20) 10 × 21.9 10 ] ๐๐๐๐บ ′ = ๐๐๐ [ 12.9 1 [[๐๐๐(16.20) 10 + ๐๐๐(21.9) − ๐๐๐(12.9)]] 10 1 [10 ๐๐๐(16.20) + ๐๐๐(21.9) − ๐๐๐(12.9)] 10 ๐๐๐๐บ ′ = ๐๐๐๐บ ′ = 1 [10 (1.2095) + 1.3404 − 1.1106] 10 1 [10 (1.2095) + 1.3404 − 1.1106] = 1.2325 10 ๐๐๐๐บ ′ = 1.2325 ๐บ ′ = ๐ด๐๐ก๐๐๐๐(1.2325) = 17.08 Harmonic Mean: If ๐1 , ๐2 , ๐3 , … , ๐๐ is a given ๐ set of observations, then their harmonic mean, abbreviated as H.M. 1 ๐ป=1 1 1 1 1 [ + + +โฏ+ ] ๐๐ ๐ ๐1 ๐2 ๐3 ๐ป=1 ๐ (Or) 1 1 ∑( ) ๐ Harmonic mean is the value of the variable or the mid-value of the class (in case of grouped or continuous frequency distribution) and ๐ is the corresponding frequency of ๐. In case of frequency distribution, we have ๐๐ 1 1 ๐1 ๐2 = ( + + โฏ+ ) ๐๐ ๐ป ๐ ๐1 ๐2 ๐ป= ๐ = where, ๐ = ∑ ๐ , ∑( 1 ) ๐ 1 ๐ ∑( ) ๐ ๐ ๐= mid-value of the variable or mid-value of the class ๐= frequency of ๐ Example 1: A cyclist pedals from his house to his college at a speed of 10 kmph and back from college to his house at 15 kmph. Find the average speed. Solution: Let the distance from house to college be ๐ฅ ๐๐. ๐ฅ In going from house to college, the distance ๐ฅ ๐๐ is covered by 10 hours, while in coming from college to house, the distance covered in Total distance of 2๐ฅ ๐๐ is covered in ( ๐ฅ ๐ฅ 15 10 + hours. ๐ฅ 15 ) hours. ๐ก๐๐ก๐๐ ๐๐๐ ๐ก๐๐๐๐ ๐๐๐ฃ๐๐๐๐ ๐ก๐๐ก๐๐ ๐ก๐๐๐ ๐๐ก๐๐๐ 2๐ฅ 2๐ฅ = 12 ๐๐๐h = ๐ฅ ๐ฅ = 1 ( + ) ( + 1) 10 15 10 15 ๐ด๐ฃ๐๐๐๐๐ ๐ ๐๐๐๐ = Example 2: A vehicle when climbing up a gradient, consumes petrol at the rate of 1 liter per 8 km. While coming down it gives 12 km per liter. Find its average consumption for to and fro travel between two places situated at the two ends of a 25 km long gradient. Verify your answer? Solution: Since the consumption of petrol is different for upward and downward journeys (at a constant speed of 25 km), the appropriate average consumption for to and fro journey is given by harmonic mean of 8km and 12 km. ๐ด๐ฃ๐๐๐๐๐ ๐๐๐๐ ๐ข๐๐๐ก๐๐๐ = 2 1 1 ( + ) 8 12 = 48 = 9.6 ๐๐/๐๐๐ก๐๐ 5 Example 3: In a certain office, a letter is typed by ๐ด in 4 times. The same letter is typed by ๐ต, ๐ถ, ๐๐๐ ๐ท are 5,6,10 minutes respectively. What is the average time taken in completing one letter? How many letters do you expect to be typed in one day comprising of 8 working hours? Solution: The average time taken by each of ๐ด, ๐ต, ๐ถ, ๐๐๐ ๐ท in competing one letter is the harmonic mean of 4,5,6, and 10. 4 4 240 1 1 1 1 = 15 + 12 + 1 + 6 = 43 = 5.5814 ๐๐๐/๐๐๐ก๐ก๐๐ + + + ) 4 5 6 10 ( 60 Expected no. of letters typed by each of ๐ด, ๐ต, ๐ถ, ๐๐๐ ๐ท is In a day comprising 8 hours = 8 × 60 minutes. 43 240 letters/min. 43 Total letters typed all of them ๐ด, ๐ต, ๐ถ, ๐๐๐ ๐ท = 240 × 4 × 8 × 60 = 344. Measures of variability (dispersion) : Dispersion is the variation of the values which helps one to known as how the variates are closely passed around or widely scattered away from the point of central tendency. The various measures of dispersion are: Range Quartile Deviation Mean deviation or Absolute Mean deviation Standard Deviation Range: Range is the difference between the greatest (maximum) and the smallest (minimum) observation of the distribution. ๐ ๐๐๐๐ = ๐๐๐๐ฅ − ๐๐๐๐ Example 1: Find the range of the following distribution Class interval 0-2 2-4 4-6 6-8 8-10 10-12 Frequency 5 16 13 7 5 4 Solution: ๐ ๐๐๐๐ = ๐๐๐๐ฅ − ๐๐๐๐ = 12 − 0 = 12 Example 2: The following table given the age of distribution of a group 50 individuals Age (in years) 16-20 21-25 26-30 31-36 No. of persons 10 15 17 8 Solution: Age (in years) No. of persons 15.5-20.5 10 20.5-25.5 15 25.5-30.5 17 30.5-35.5 8 ๐ ๐๐๐๐ = ๐๐๐๐ฅ − ๐๐๐๐ = 35.5 − 15.5 = 20 Quartile deviation: It is a measure of dispersion based on the upper quartile ๐3 and the lower quartile ๐1 . ๐๐ข๐๐๐ก๐๐๐ ๐๐๐ฃ๐๐๐ก๐๐๐ (๐. ๐ท) = h ๐∗๐ where ๐๐ = ๐ + ( ๐ 4 ๐3 − ๐1 2 − ๐) , ๐๐๐ ๐ = 1,2,3 ๐1 = ๐๐๐๐ ๐ก ๐๐ข๐๐๐ก๐๐๐ ๐๐๐ฃ๐๐๐ก๐๐๐ ๐2 = ๐ ๐๐๐๐๐ ๐๐ข๐๐๐ก๐๐๐ ๐๐๐ฃ๐๐๐ก๐๐๐ ๐3 = ๐กh๐๐๐ ๐๐ข๐๐๐ก๐๐๐ ๐๐๐ฃ๐๐๐ก๐๐๐ Mean Deviation (or) absolute Mean Deviation: For ungrouped data or raw data: Or frequency distribution: (Or) 1 ๐. ๐ท = ∑|๐ฅ๐ − ๐ฅฬ | ๐ ๐ ๐. ๐ท = 1 ∑ ๐๐ |๐ฅ๐ − ๐ฅฬ | ๐ ๐ If ๐๐ , ๐ = 1,2,3, … , ๐ is the frequency distribution corresponding observations ๐ฅ ๐ , then mean deviation from average (usually mean, median and mode) is given by; 1 Mean deviation from average ๐ด = ๐ ∑๐๐=1 ๐๐ |๐ฅ๐ − ๐ด| , ∑๐ ๐๐ = ๐, where |๐ฅ ๐ − ๐ด| represents modulus or absolute value of the deviation (๐ฅ ๐ − ๐ด), where negative sign ignored. Example: Calculate the Mean deviation from the following data: Marks 0-10 10-20 20-30 30-40 40-50 50-60 60-70 No. of students 6 5 8 15 7 6 3 Solution: 1 Mean deviation from average ๐ด = ∑๐๐=1 ๐๐ |๐ฅ๐ − ๐ด| ๐ 1 We have to find the mean deviation from mean is ๐. ๐ท = ๐ ∑ ๐ |๐ฅ − ๐ฅฬ | So, first we have to find the mean ๐ฅฬ . ๐ฅฬ = ๐ด + h ∑ ๐๐ ๐ ๐ฅ − 35 h -3 -18 5 -2 -10 25 8 -1 -8 30-40 35 15 0 0 40-50 45 7 1 7 50-60 55 6 2 12 60-70 65 3 3 9 Mid-value (๐ฅ ) 5 No. of students (๐) 10-20 15 20-30 Marks 0-10 6 ๐= ๐ = 50 ∑ ๐๐ = −8 ๐ฅฬ = ๐ด + ๐ฅฬ = 35 + Marks 0-10 Mid-value (๐ฅ ) 10-20 20-30 5 ๐๐ h ∑ ๐๐ ๐ 10 (−8) = 33.4 ๐๐๐๐๐ 50 No. of students (๐) ๐ = ๐ฅ − 35 h ๐|๐ฅ − ๐ฅฬ | -18 |๐ฅ − ๐ฅฬ | = |๐ฅ − 33.4| 28.4 170.4 ๐๐ 6 -3 15 5 -2 -10 18.4 92 25 8 -1 -8 8.4 67.2 30-40 35 15 0 0 1.6 24 40-50 45 7 1 7 11.6 81.2 50-60 55 6 2 12 21.6 129.6 60-70 65 3 3 9 31.6 94.8 ๐ = 50 ๐. ๐ท = Standard Deviation: ∑ ๐ |๐ฅ − ๐ฅฬ | 659.2 1 ∑ ๐ |๐ฅ − ๐ฅฬ | = = 13.184 50 ๐ = 659.2 1 1 ๐๐๐๐๐๐๐๐ = ∑(๐ฅ๐ − ๐ฅฬ ) 2 = ∑ ๐ฅ๐ 2 − ๐ฅฬ 2 ๐ ๐ 1 1 ๐๐ก๐๐๐๐๐๐ ๐ท๐๐ฃ๐๐๐ก๐๐๐ = ๐. ๐ท = ๐ = √ ∑(๐ฅ ๐ − ๐ฅฬ ) 2 (or) √ ∑ ๐ฅ๐ 2 − ๐ฅฬ 2 Coefficient of dispersion = ๐3 −๐1 ๐3 +๐1 ๐ ๐ Coefficient of variation= ๐ถ. ๐ = 100 × ๐ ๐ฅฬ Example 1: Lives of two modes of refrigerators recorded in a received survey are given in the following table. Find the average life of each model. Which model shows more uniformity? Life (No. of years) Model A Model B 0-2 5 2 2-4 16 7 4-6 13 12 8-6 7 19 8-10 5 9 10-12 4 1 Solution: ๐ฅ2 0-2 Midvalue (๐ฅ ) 1 1 2-4 3 4-6 Life (No. of years) Model Model ๐๐ด ๐๐ต ๐ฅ −๐ด ๐ฅ −๐ต A B = = h ๐๐ต ๐๐ต ๐๐ด ๐ฅ 2 ๐๐ต ๐ฅ 2 (๐๐ด ) 5 ( ๐๐ต ) 2 -1 -3 -5 -6 5 2 9 16 7 0 -2 0 -14 144 63 5 25 13 12 1 -1 13 -12 325 300 8-6 7 49 7 19 2 0 14 0 343 931 8-10 9 81 5 9 3 1 15 9 405 729 10-12 11 121 4 1 4 2 16 2 484 121 ∑ ๐ฅ2 ๐ = 50 ๐ = 50 ∑ ๐๐ด ๐๐ด ∑ ๐๐ต ๐๐ต = 286 h ๐๐ด ๐๐ด ๐ฅฬ ๐ด = ๐ด + h (∑ ๐๐ด ๐๐ด ) ๐ ๐ฅฬ ๐ต = ๐ต + h (∑ ๐๐ต ๐๐ต ) ๐ = 3+ =7+ = 53 2 (53) = 5.12 50 2 (−21) = 6.16 50 1 ๐๐ด = √ ∑ ๐๐ด ๐ฅ๐ 2 − ๐ฅฬ 2๐ด ๐ 1 = √ × 286 − (5.12) 2 = 2.8115 50 1 ๐๐ต = √ ∑ ๐๐ต ๐ฅ ๐2 − ๐ฅฬ 2 ๐ต ๐ = − 21 1706 2146 1 = √ × 2146 − (6.16) 2 = 2.23 50 ๐๐ด = 53.95 ๐ฅฬ ๐ด ๐๐ต ๐ถ๐๐ต = 100 × = 36.20 ๐ฅฬ ๐ต ๐ถ๐๐ด = 100 × ๐ถ๐๐ต < ๐ถ๐๐ด Therefore, Model B has more uniformity. Example 2: Find the range, all three quartiles, quartile deviation, mean deviation, absolute mean deviation and standard deviation for the following distribution Class Interval frequency Cumulative frequency (c. f) 0-2 5 5 2-4 16 21 4-6 13 34 6-8 7 41 8-10 5 46 10-12 4 50 Solution: Range: ๐ ๐๐๐๐ = ๐๐๐๐ฅ − ๐๐๐๐ = 12 − 0 = 12 Quartiles: h ๐ ๐1 = ๐ + ( − ๐) ๐ 4 ๐ = 2, h = 2, ๐ = 16, ๐ = 5, ๐ = 50 ๐1 = 2.9375 h ๐ ๐2 = ๐ + ( − ๐) ๐ 2 ๐ = 4, h = 2, ๐ = 13, ๐ = 21, ๐ = 50 ๐2 = 4.6153 h 3๐ ๐3 = ๐ + ( − ๐) ๐ 4 ๐ = 6, h = 2, ๐ = 7, ๐ = 34, ๐ = 50 ๐3 = 7 ๐. ๐ท = 7 − 2.9375 = 2.0312 2 Mean Deviation: ๐. ๐ท = 1 ∑ ๐. (๐ฅ − ๐ฅฬ ) ๐ ๐. ๐ท = 1 ∑ ๐๐ . |๐ฅ๐ − ๐ฅฬ | ๐ Absolute Mean Deviation: Standard Deviation: ๐ 1 ๐. ๐ท = ๐ = √ ∑ ๐ฅ ๐2 − ๐ฅฬ 2 ๐ Moments, Skewness and Kurtosis: Moments: The ๐๐กh moment of a variable ๐ฅ about any point ๐ฅ = ๐ด, usually denoted by ๐๐ ′ is given by: 1 ๐ ๐ ′ = ∑๐ ๐๐ (๐ฅ๐ − ๐ด ) ๐, ∑๐ ๐๐ = ๐ (1) ๐ 1 ๐ ๐ ′ = ∑๐ ๐๐ ๐๐ ๐, ๐คh๐๐๐ ๐๐ = ๐ฅ๐ − ๐ด (2) ๐ The ๐๐กh moment of a variable ๐ฅ about the mean ๐ฅฬ , usually denoted by ๐๐ is given by: 1 ๐ ๐ = ∑๐ ๐๐ ๐ง๐ ๐ , ๐คh๐๐๐ ๐ง๐ = ๐ฅ ๐ − ๐ฅฬ ๐ (3) 1 1 In particular, ๐0 = ๐ ∑๐ ๐๐ (๐ฅ ๐ − ๐ฅฬ )0 = 1 , ๐1 = ๐ ∑๐ ๐๐ (๐ฅ๐ − ๐ฅฬ )1 = 0 , ๐2 = 1 ๐ ∑๐ ๐๐ (๐ฅ๐ − ๐ฅฬ )2 = ๐ 2 , … We know that if ๐๐ = ๐ฅ ๐ − ๐ด, then 1 ๐ฅฬ = ๐ด + ∑๐ ๐๐ ๐๐ = ๐ด + ๐1 ′ (4) ๐ Relation between Moments about Mean in terms of Moments about any point and vice versa: 1 1 ๐ ๐ = ∑๐ ๐๐ (๐ฅ ๐ − ๐ฅฬ ) ๐ = ∑๐ ๐๐ (๐ฅ๐ − A + A − ๐ฅฬ ) ๐ = ๐ Using eq. (4), we get 1 ๐ ๐๐ = 1 ๐ ∑๐ ๐๐ (๐๐ + A − ๐ฅฬ ) ๐ , where ๐๐ = ๐ฅ ๐ − ๐ด. 1 ∑ ๐๐ (๐๐ − ๐1 ′ )๐ ๐ ๐ 2 3 ๐ ๐ ๐ = ∑๐ ๐๐ (๐๐ ๐ − ๐๐ถ1 ๐๐ ๐−1 ๐1 ′ + ๐๐ถ2 ๐๐ ๐−2 ๐1 ′ − ๐๐ถ3 ๐๐ ๐−3 ๐1 ′ + โฏ + (−1) ๐๐1 ′ ) ๐ 2 3 ๐ (5) ๐ ๐ = ๐ ๐′ − ๐๐ถ1 ๐ ๐−1 ′ ๐1 ′ + ๐๐ถ2 ๐ ๐−2 ′ ๐1 ′ − ๐๐ถ3 ๐๐−3 ′๐1 ′ + โฏ + (−1) ๐ ๐1 ′ (Using eq. (3)) In particular on putting ๐ = 2,3 ๐๐๐ 4 in eq. (5) and simplifying, we get ๐ 2 = ๐ 2 ′ − ๐1 ′ 2 ๐ 3 = ๐ 3 ′ − 3๐ 2 ′๐1′ + 2๐1 ′ 2 3 ๐ 4 = ๐ 4′ − 4๐ 3 ′ ๐1 ′ + 6๐ 2 ′๐1 ′ − 3๐1 ′ 1 1 4 1 ๐ ๐ ′ = ∑๐ ๐๐ (๐ฅ๐ − ๐ด ) ๐ = ∑๐ ๐๐ (๐ฅ๐ − ๐ฅฬ + ๐ฅฬ − ๐ด ) ๐ = ∑๐ ๐๐ (๐ง๐ + ๐1 ′ )๐, ๐ ๐ ๐ where ๐ฅ ๐ − ๐ฅฬ = ๐ง๐ ๐๐๐ ๐ฅฬ = ๐ด + ๐1 ′ Thus ๐๐ ′ = 1 ๐ ∑๐ ๐๐ (๐ง๐ ๐ + ๐๐ถ1 ๐ง๐ ๐−1 ๐1 ′ + ๐๐ถ2 ๐ง๐ ๐−2 ๐1 ′ 2 + ๐๐ถ3 ๐ง๐ ๐−3 ๐1 ′ 3 + โฏ + ๐1 ′ ๐ ) 2 = ๐ ๐ + ๐๐ถ1 ๐ ๐−1 ๐1 ′ + ๐๐ถ2 ๐๐−2 ๐1 ′ + โฏ + ๐1 ′ ๐ In particular on putting ๐ = 2,3, 4 ๐๐๐ ๐๐๐ก๐๐๐ ๐กh๐๐ก ๐1 = 0 , we get ๐ 2 ′ = ๐ 2 + ๐1 ′ 2 ๐ 3 ′ = ๐ 3 + 3๐ 2 ๐1 ′ + ๐1 ′ 2 3 ๐ 4 ′ = ๐ 4 + 4๐ 3๐1 ′ + 6๐ 2 ๐1 ′ + ๐1 ′ 4 These formulae unable to find the moments about any point, once the mean and the moments about mean are known. Pearson’s ๐ท ๐๐๐ ๐ธ Coefficients: Karl Pearson defined the following four coefficients, based upon the first four moments about mean: ๐ฝ1 = ๐ 32 ๐4 , ๐พ1 = +√๐ฝ1 ๐๐๐ ๐ฝ2 = 2 , ๐พ2 = ๐ฝ2 − 3 3 ๐2 ๐2 It may be pointed out that these coefficients are pure numbers independent of units of measurement. Example: Calculate the first four moments of the following distribution about the mean and hence find ๐ฝ1 ๐๐๐ ๐ฝ2 . ๐ฅ ๐ 0 1 2 3 4 5 6 7 8 1 8 28 56 70 56 28 8 1 Solution: ๐๐ ๐๐2 ๐๐ 3 ๐๐ 4 1 ๐ =๐ฅ −4 -4 -4 16 -64 256 1 8 -3 -24 72 -216 648 2 28 -2 -56 112 -224 448 3 56 -1 -56 56 -56 56 4 70 0 0 0 0 0 5 56 1 56 56 56 56 6 28 2 56 112 224 448 7 8 3 24 72 216 648 8 1 4 4 16 64 256 Total ๐ต= ๐๐๐ 0 ∑ ๐๐ ∑ ๐๐ ๐ = 512 ∑ ๐๐ ๐ = 0 ∑ ๐๐ ๐ = 2816 ๐ฅ ๐ 0 =๐ Moments about the point ๐ฅ = 4 are 1 512 1 ∑ ๐๐ = 0, ๐ 2 ′ = ∑๐๐ 2 = = 2, ๐ 256 ๐ 1 1 2816 ๐ 3 ′ = ∑๐๐ 3 = 0, ๐ 4 ′ = ∑ ๐๐ 4 = = 11 ๐ ๐ 256 ๐1 ′ = Moments about mean are 2 3 ๐1 = 0, ๐ 2 = ๐ 2 ′ − ๐1 ′ = 2, ๐ 3 = ๐ 3′ − 3๐ 2 ′ ๐1 ′ + 2๐1 ′ = 0 2 4 ๐ 4 = ๐ 4′ − 4๐ 3 ′ ๐1 ′ + 6๐ 2 ′๐1 ′ − 3๐1 ′ = 11 ๐ฝ1 = ๐32 = 0, ๐23 Skewness and Kurtosis: ๐ฝ2 = ๐ 4 11 = = 2.75 ๐ 22 4 Skewness: Literally, skewness means lack of symmetry i.e., skewness to have an idea about the shape of the curve which can draw with help of the given data. A distribution is said to be skewed, if ๏ง ๏ง ๏ง Mean(๐), median ๐๐ and mode ๐0 fall at different points i.e., ๐๐๐๐ ≠ ๐๐๐๐๐๐ ≠ ๐๐๐๐ Quartiles are not equidistant from median The curve drawn with the help of the given data is not symmetrical but stretched more to one side than to the other. Measures of Skewness: Various measures of skewness (๐๐ ) are: ๏ง ๏ง ๏ง ๐๐ = ๐ − ๐๐ ๐๐ = ๐ − ๐0 ๐๐ = (๐3 − ๐๐ ) − (๐๐ − ๐1 ) These are the absolute measures of skewness. 1. Prof. Karl Pearson’s Coefficient of Skewness: ๐๐ = ๐−๐0 , ๐ is the standard deviation of the distribution. If mode is ill-defined, then using the empirical relation, ๐0 = 3๐๐ − 2๐, for a moderately asymmetrical distribution, we get ๐ ๐๐ = 3(๐ − ๐๐ ) ๐ ๐๐ = 0, if ๐ = ๐0 = ๐๐. Hence for a symmetrical distribution all are coincide. 2. Prof. Bowley’s Coefficient of Skewness: ๐๐ = ( ๐3 − ๐๐ ) − (๐๐ − ๐1 ) ๐3 + ๐1 − 2๐๐ = ( ๐3 − ๐๐ ) + (๐๐ − ๐1 ) ๐3 − ๐1 ๐๐ = 0, if ๐3 − ๐๐ = ๐๐ − ๐1. Hence for a symmetrical distribution. Median is equidistant from the upper and lower quartiles. 3. Based upon the moments, coefficient of skewness: √๐ฝ1 (๐ฝ2 + 3) 2 (5๐ฝ2 − 6๐ฝ1 − 9) ๐๐ = 0, if either ๐ฝ1 = 0 or ๐ฝ2 = −3 ๐๐ = Kurtosis : ๏ง ๏ง ๏ง Prof. Karl Pearson’s calls as the ‘convexity of the frequency curve’ or Kurtosis. Kurtosis enables the flatness or peakedness of the frequency curve. It is measured by the coefficient ๐ฝ2 or its derivation is given by ๐ ๐ฝ2 = 42 , ๐พ2 = ๐ฝ2 − 3 ๐ 2 A: Leptokurtic Curve (which is more peaked than the normal curve๐ฝ2 > 3 ๐. ๐. ๐พ2 > 0 ) B: Normal Curve or Mesokurtic Curve (which is neither flat nor peaked ๐ฝ2 = 3 ๐. ๐. ๐พ2 = 0 ) C: Platykurtic Curve (which is flatter than the normal curve ๐ฝ2 < 3 ๐. ๐. ๐พ2 < 0) Example 1: For a distribution, the mean is 10, variance is 16, ๐พ1 is +1 and ๐ฝ2 is 4. Obtain the first four moments about the origin, i.e. zero. Comment upon the nature of distribution. Solution: Given that Mean=10, ๐2 = 16, ๐กh๐๐ ๐. ๐ท = 4, ๐พ1 = + 1 and ๐ฝ2 = 4 First four moments about the origin is ๐1 ′ , ๐2 ′ , ๐3 ′ , ๐4 ′ . ๐1 ′ = ๐๐๐๐ ๐ก ๐๐๐๐๐๐ก ๐๐๐๐ข๐ก ๐กh๐ ๐๐๐๐๐๐ = ๐๐๐๐ = 10 ′ 2 2 ๐ 2 = ๐ 2 ′ − ๐1 ′ ๐กh๐๐ ๐ 2 = ๐ 2 + ๐1 ′ = 16 + 100 = 116 We have ๐พ1 = + 1 then ๐3 ๐2 3/2 ๐ = ๐33 = 1 ๐๐ ๐3 = ๐ 3 = 64 Therefore , ๐3 = ๐3 ′ − 3๐2 ′ ๐1 ′ + 2๐1 ′ 3 ๐ 3 ๐ 3 ′ = ๐ 3 + 3๐ 2 ๐1′ + ๐1 ′ = 64 + 3(116)(1) − 2(1000) = 1544 Now ๐ฝ2 = ๐ 42 = 4, then ๐4 = 4(256) = 1024 2 2 ๐ 4 = ๐ 4′ − 4๐ 3 ′ ๐1 ′ + 6๐ 2 ′๐1 ′ − 3๐1 ′ 4 ๐ 4 = 1024 + 4 (1,544)(10) − 6(116)(100) + 3(10,000) = 23,184 Comments on nature of the distribution: Since ๐พ1 = +1, the distribution is moderately positively skewed, i.e., if we draw the curve of given distribution, it will have longer tail towards the right. Further since ๐ฝ2 = 4 > 3, the distribution is leptokurtic, i.e., it will be slightly more peaked than the normal curve. Example 2: For the frequency distribution of scores in mathematics of 50 candidates selected at random from among those appearing at a certain examination, compute the first four moments about the mean of the distribution. Scores Frequency 50-60 1 60-70 0 70-80 0 80-90 1 90-100 1 100-110 2 110-120 1 120-130 0 130-140 4 140-150 4 150-160 2 160-170 5 170-180 10 180-190 11 190-200 4 200-210 1 210-220 1 220-230 2 Find also find the correct values of the moments after Sheppard’s corrections are applied. Also obtain moment coefficient of skewness and kurtosis and comment on the nature of the distribution. Solution: ๐ฅ −4 10 ๐๐ ๐๐ 2 ๐๐ 3 ๐๐ 4 -8 -8 64 -512 4096 0 -7 0 0 0 0 0 -6 0 0 0 Mid-value (๐ฅ ) frequency 55 (๐) 65 75 1 ๐= 85 1 -5 -5 25 -125 625 95 1 -4 -4 16 -64 256 105 2 -3 -6 18 -54 162 115 1 -2 -2 4 -8 16 125 0 -1 0 0 0 0 135 4 0 0 0 0 0 145 4 1 4 4 4 4 155 2 2 4 8 16 32 165 5 3 15 45 135 405 175 10 4 40 160 640 2560 185 11 5 55 275 1375 6875 195 4 6 24 144 864 5184 205 1 7 7 49 343 2401 215 1 8 8 64 512 4096 225 2 9 18 162 1458 13122 Total 50 150 1038 4584 39834 The raw moments of variable ๐ (about origin) are computed as ๐1 ′ = ๐ 3′ = 1 150 1 1038 ∑ ๐๐ = = 3, ๐ 2 ′ = ∑๐๐ 2 = = 20.76, ๐ 50 ๐ 50 1 4584 1 39834 ∑ ๐๐ 3 = = 91.68, ๐ 4 ′ = ∑ ๐๐ 4 = = 796.68 ๐ 50 ๐ 50 The central moments of variable ๐ are then computed as shown below 2 ๐ 2 = (๐ 2 ′ − ๐1 ′ ) × h2 = (20.76 − 9) × 100 = 1176 3 ๐ 3 = (๐ 3 ′ − 3๐ 2 ′๐1′ + 3๐1 ′ ) × h3 = (91.68 − 3 × 20.76 × 3 + 2(27)) × 1000 = −41160 2 4 ๐ 4 = (๐ 4 ′ − 4๐ 3 ′๐1 ′ + 6๐ 2′ ๐1′ − 3๐1 ′ ) × h4 = (796.68 − 4 × 91.68 × 3 + 6 × 20.76 × 9 − 3 × 91) × 10000 = 5687091.67 Sheppard’s corrections for moments: ๐2 = ๐2 − ฬ ฬ ฬ ๐ฬ ฬ ฬ 4 = ๐ 4 − h2 100 = 1176 − = 1167.67 12 12 h2 = −41160 12 ๐ฬ ฬ ฬ 3 = ๐ 3 − h2 7 4 ๐2 + h = 5745600 − 58800 + 291.67 = 5687091.67 2 240 Moment coefficient of skewness is given by ๐พ1 = √๐ฝ1 = Moment coefficient of kurtosis=๐ฝ2 = ๐3 ๐ 23/2 ๐4 ๐2 2 = = −41160 1176√1176 5745600 ( 1176 ) 2 Comments on nature of the distribution: = −1.02 = 4.15 Since ๐พ1 = −1.02 is negative, the distribution is moderately negatively skewed, i.e., the frequency curve of the given distribution has a longer tail towards the left. Further, since ๐ฝ2 = 4.15 > 3 is positive the distribution is leptokurtic, i.e., the frequency curve is more peaked than the normal curve. Combined Mean: Given the sample size Sample mean Combined mean Also, sample variance Combined variance Example: ๐ฅฬ ฬ ฬ 1 ๐ฅฬ = ๐1 ๐2 ๐ฅ ฬ ฬ ฬ 2 ๐1 ฬ ฬ ๐ฅฬ ฬ +๐ ๐ฅฬ ฬ 1 2 ฬ ฬ 2 ๐1 + ๐2 ๐1 2 ๐2 = ๐2 2 ๐1 (๐1 2 +๐1 2 ) +๐2 (๐2 2 +๐2 2 ) ๐1 + ๐2 ๐1 = ๐ฅ1 − ๐ฅฬ A distribution consists of three 25 measurements, it was found that the mean and standard deviation are 36 cm and 12 cm. after these results were calculated, it was noticed that 2 measurements were wrongly recorded as 60 cm and 36 cm, instead of 40 cm and 3 cm. find the corrected values of the mean and standard deviation. Solution: Given that ๐ = 25, ๐ฅฬ = 36, ๐ = 12 We know that, ๐ฅฬ = ∑ ๐ฅ๐ ๐ ∑ ๐ฅ ๐ = ๐. ๐ฅฬ = 25 × 36 = 900 1 ๐ 2 = ∑ ๐ฅ ๐ 2 − ๐ฅฬ 2 ๐ ∑ ๐ฅ ๐ 2 = ๐(๐ 2 + ๐ฅฬ 2 ) = 25 (144 + 296) = 36000 Corrected ∑ ๐ฅ ๐ = 900 − 60 − 36 + 40 + 30 = 874 Corrected ∑ ๐ฅ ๐ 2 = 36000 − 602 − 362 + 402 + 302 = 33604 Corrected mean= ๐๐๐๐๐๐๐ก๐๐ ∑ ๐ฅ ๐ ๐ Corrected variance(๐ 2 ) = = 33604 25 874 25 = 34.96 − (34.96)2 = 121.96 Corrected standard deviation (๐) = √ 121.96 = 11.04 Module 2 Probability Random experiment: If an experiment is conducted, any number of times, under essentially identical conditions, there is a set of all possible outcomes associated with it. If the result is not certain and is anyone of the several possible outcomes, the experiment is called a random trail or a random experiment. The outcomes are known as elementary events and a set of outcomes is an event. Thus, an elementary event is also an event. Equally likely events: Events are said to be equally likely when there is no reason to expect anyone of them rather than anyone of the others. Example: When a card is drawn from a pack, any card may be obtained. In this trail, all the 52 elementary events are equally likely. Exhaustive Events: All possible events in any trial are known as exhaustive events. Example: 1. In tossing a coin, there are two exhaustive elementary events, like head and tail. 2. In throwing a die, there are six exhaustive elementary events i.e., getting 1 or 2 or 3 or 4 or 5 or 6. Mutually exclusive events: Events are said to be mutually exclusive, if the happening of anyone of the events in a trial excludes the happening of any one of the others i.e., if no two or more of the events can happen simultaneously in the same trial. Probability: If a random experiment or a trial results ‘n’ exhaustive, mutually exclusive and equally likely outcomes, out of which ‘m’ are favorable to the to the occurrence of event E, then the probability ‘p’ of occurrence or happening of E, usually denoted by P(E), is given by ๐ = ๐(๐ธ) = Note: ๐ ๐๐. ๐๐ ๐๐๐ฃ๐๐ข๐๐๐๐๐ ๐๐๐ ๐๐ = ๐ก๐๐ก๐๐ ๐๐. ๐๐ ๐๐ฅh๐๐ข๐ ๐ก๐๐ฃ๐ ๐๐๐ ๐๐ ๐ 1. Since ๐ ≥ 0, ๐ > 0 ๐๐๐ ๐ ≤ ๐, we get ๐(๐ธ) ≥ 0 and ๐(๐ธ) ≤ 1, then 0 ≤ ๐(๐ธ) ≤ 1 or 0 ≤ ๐(๐ธฬ ) ≤ 1. 2. The non-happening of the event ๐ธ is called the complementary event of ๐ธ and is denoted by ๐ธฬ ๐๐ ๐ธ ๐ . The number of cases favorable to ๐ธ i.e., non-happening of ๐ธ is ๐ − ๐. Then the probability ๐ that ๐ธ will not happen is given by: ๐−๐ ๐ ๐ = ๐(๐ธฬ ) = = 1 − = 1 − ๐. ๐ Then, ๐ + ๐ = 1 ๐ ๐ = ๐(๐ธฬ ) = 1 − ๐(๐ธ) ๐(๐ธ) = 1 − ๐(๐ธฬ ) ๐(๐ธ) + ๐(๐ธฬ ) = 1 3. If ๐(๐ธ) = 1, ๐ธ ๐๐ ๐๐๐๐๐๐ certain event and if ๐(๐ธ) = 0, ๐ธ is called impossible event. Example 1. What is the chance of getting 4 on rolling a die. Solution: There are six possible ways in which die can roll. There is one way of getting 4. 1 i.e., the required choice of getting 4 is . 6 2. What is the chance of that a leap year selected at random will contain 53 Sundays. Solution: Number of days in a leap year is 366. Number of full weeks, in a leap year 52+ 2 days. These two days can be any one of the following 7 ways. Out of these 7 cases the last two are favorable. 2 Hence the required probability is . Simple Event: 7 An event in a trial that cannot be further split is called a simple event or an elementary event. Sample space: The set of all possible simple events in a trial is called a sample space for the trial. Each element of a sample space is called a sample point. Example: Two coins are tossed, then the possible simple events of the trial are HH, HT, TH, TT. i.e., the sample space is ๐ = {HH, HT, TH, TT} Axioms of Probability: Let ๐ธ be the random experiment whose sample space is ๐. If ๐ถ is a subset of sample space. We define the following three axioms: 1. ๐(๐ถ) ≥ 0, for every ๐ถ ⊆ S 2. ๐(๐) = 1 3. ๐(๐ถ1 ∪ ๐ถ2 ∪ ๐ถ3 ∪ … ) = ๐(๐ถ1) + ๐(๐ถ2) + ๐(๐ถ3) + โฏ, where ๐ถ1, ๐ถ2, ๐ถ3, … are subsets of ๐ and they are mutually disjoint. i.e., ๐ถ1 ∩ ๐ถ2 = ∅, ๐๐๐ ๐ ≠ ๐. Properties of the probability function: 1. For each ๐ถ ⊆ ๐, ๐(๐ถ) = 1 − ๐(๐ถ ∗ ), where ๐ถ ∗ is the compliment of ๐ถ in ๐. 2. The Probability of null set is zero, i.e., ๐(∅) = 0, 3. If ๐ถ1 and ๐ถ2 are subsets of ๐ such that then ๐(๐ถ1) ≤ ๐(๐ถ2). 4. ๐ถ ⊂ ๐, 0 ≤ ๐(๐ถ) ≤ 1 5. If ๐ถ1 and ๐ถ2 are subsets of ๐ such then ๐(๐ถ1 ∪ ๐ถ2) = ๐(๐ถ1) + ๐(๐ถ2) − ๐(๐ถ1 ∩ ๐ถ2). Example: If the sample space is , ๐ = ๐ถ1 ∪ ๐ถ2, if ๐(๐ถ1) = 0.8, ๐(๐ถ2) = 0.5 then find ๐(๐ถ1 ∩ ๐ถ2). Solution: Given that ๐ = ๐ถ1 ∪ ๐ถ2, ๐(๐ถ1) = 0.8, ๐(๐ถ2) = 0.5 By the addition law of probability ๐(๐ถ1 ∪ ๐ถ2) = ๐(๐ถ1) + ๐(๐ถ2) − ๐(๐ถ1 ∩ ๐ถ2) ๐(๐ถ1 ∩ ๐ถ2) = ๐(๐ถ1) + ๐(๐ถ2) − ๐(๐) = 1.3 − 1 = 0.3. ๐(๐ถ1 ∩ ๐ถ2) = 0.8 + 0.5 − 1 Conditional Event: If ๐ถ1, ๐ถ2 are events of a sample space ๐ and if ๐ถ2 occurs after the occurrence of ๐ถ1, then the event of occurrence of ๐ถ2 after the event ๐ถ1 called conditional event of ๐ถ2 given ๐ถ1. It is denoted by Examples: ๐ถ2 ๐ถ1 . Similarly, we define ๐ถ1 ๐ถ2 . 1. Two coins are tossed. The event of getting two tails given that there is at least one tail is a conditional event. 2. A die is thrown three times. The event of getting the sum of the numbers thrown is 15 when it is known that the first throw was a 5 is a conditional event. Conditional Probability: Let ๐ be the sample space of a random experiment. Let ๐ถ1 ⊂ ๐, further let ๐ถ2 ⊂ ๐ถ1, then the conditional event ๐ถ1has already occurred, denoted by ๐(๐ถ2/๐ถ1) is defined as Or Note: ๐(๐ถ2/๐ถ1) = ๐(๐ถ2 ∩ ๐ถ1) , ๐๐ ๐(๐ถ1) ≠ 0 ๐(๐ถ1 ) ๐(๐ถ2 ∩ ๐ถ1) = ๐(๐ถ1)๐(๐ถ2/๐ถ1) 1. If๐ถ1, ๐ถ2, ๐ถ3 are any three events, then ๐(๐ถ1 ∩ ๐ถ2 ∩ ๐ถ3) = ๐(๐ถ1)๐(๐ถ2/๐ถ1)๐(๐ถ3/๐ถ1 ∩ ๐ถ2) 2. For any events ๐ถ1, ๐ถ2, ๐ถ3, … , ๐ถ๐ , then ๐(๐ถ1 ∩ ๐ถ2 ∩ ๐ถ3 ∩ … ∩ ๐ถ๐ ) = ๐(๐ถ1)๐(๐ถ2/๐ถ1)๐(๐ถ3/๐ถ1 ∩ ๐ถ2) … ๐(๐ถ๐ /๐ถ1 ∩ ๐ถ2 ∩ … ∩ ๐ถ๐ ) Examples: 1. A box contains 12 items of which 4 are defective the items are drawn at random from the box one after the other. Find the probability that all three are non-defective. Solution: There are 8 non-defective items Total no. of items=12 Let ๐ถ1, ๐ถ2, ๐ถ3 be the events getting non-defective items on first, second and third drawn. ๐(๐ถ1 ) = 8 12 ๐(๐ถ2/๐ถ1) = 7 11 ๐(๐ถ3/๐ถ1 ∩ ๐ถ2) = The probability of three are non-defective 6 10 ๐(๐ถ1 ∩ ๐ถ2 ∩ ๐ถ3) = ๐(๐ถ1)๐(๐ถ2/๐ถ1)๐(๐ถ3/๐ถ1 ∩ ๐ถ2) = 8 7 6 42 × × = 12 11 10 55 2. A box contains 20 balls of which 5 are red, 15 are white. If 3 balls are selected at random and are drawn in succession without replacement. Find the probability that all three balls selected are red. Solution: Total balls=20 Where 5 red and 15 white ๐(๐ถ1 ) = 5 20 ๐(๐ถ2/๐ถ1) = 4 19 ๐(๐ถ3/๐ถ1 ∩ ๐ถ2) = 3 18 ๐(๐ถ1 ∩ ๐ถ2 ∩ ๐ถ3) = ๐(๐ถ1)๐(๐ถ2/๐ถ1)๐(๐ถ3/๐ถ1 ∩ ๐ถ2) = 5 4 3 1 × × = 20 19 18 114 3. The probability that A hits the target is ¼ and the probability B hits is 2/5. What is the probability the target will be hit if A and B each shoot at the target? Solution: Given that ๐(๐ด) = ๐(๐ต) = 1 4 2 5 ๐(๐ด ∪ ๐ต) = ๐(๐ด) + ๐(๐ต) − ๐(๐ด ∩ ๐ต) ๐(๐ด ∪ ๐ต) = ๐(๐ด) + ๐(๐ต) − ๐(๐ด). ๐(๐ต) ๐(๐ด ∪ ๐ต) = 1 2 1 2 11 + − × = 4 5 4 5 20 Bayes theorem: Let ๐ถ1, ๐ถ2, ๐ถ3, … , ๐ถ๐ be a partition of sample space and let C be any event which is a subset of โ๐๐=1 ๐ถ๐ such that P(๐ถ) > 0, ๐กh๐๐ ๐(๐ถi /C) = ๐(๐ถ๐ )๐(๐ถ/๐ถ๐ ) . ๐ ∑๐=1 ๐(๐ถ๐ )๐(๐ถ/๐ถ๐ ) Proof: Let S be the sample space. Let ๐ถ1, ๐ถ2, ๐ถ3, … , ๐ถ๐ be a mutually disjoint event. Let ๐ถ ⊂ โ๐๐=1 ๐ถ๐ such that ๐(๐ถ) > 0 ๐ ๐ถ ⊂ โ ๐ถ๐ ๐=1 ๐ ๐ถ = ๐ถ ∩ (โ ๐ถ๐ ) ๐=1 ๐ ๐ถ = โ(๐ถ ∩ ๐ถ๐ ) ๐=1 ๐(๐ถ) = ∑๐๐=1 ๐(๐ถ ∩ ๐ถ๐ ) ๐(๐ถ) = ∑๐๐=1 ๐(๐ถ๐ )๐(๐ถ/๐ถ๐ ) Now, ๐(๐ถ๐ /๐ถ) = (1) ๐(๐ถ๐ ∩๐ถ) ๐(๐ถ) ๐(๐ถ๐ )๐(๐ถ/๐ถ๐ ) ๐(๐ถ๐ /๐ถ) = ∑๐ ๐=1 ๐(๐ถ๐ )๐(๐ถ/๐ถ๐ ) ๐(๐ถ๐ /๐ถ) = (using eq. (1)) ๐(๐ถ๐ )๐(๐ถ/๐ถ๐ ) ๐(๐ถ) Example 1: A box contains 3 blue, 2 red marbles while another box contains 2 blue, 5 red. A marble drawn at random from one of the boxes terms out to be blue. What is the probability that it come from the first box? Solution: 1 Let ๐ด1, ๐ด2 be boxes, then ๐(๐ด1 ) = and ๐(๐ด2) = 2 1 2 Let ๐ถ2 be the event of drawing blue marble ๐(๐ถ2/๐ด1) = 3 5 Let ๐ถ2 be the event of drawing blue marble ๐(๐ถ2/๐ด2) = We have to require ๐(๐ด1 /๐ถ2) = 2 7 ๐(๐ด1)๐(๐ถ2/๐ด1 ) ๐(๐ด1 )๐(๐ถ2/๐ด1) + ๐(๐ด2)๐(๐ถ2/๐ด2) 1 3 × 2 5 ๐(๐ด1 /๐ถ2) = 1 3 1 2 × + × 2 5 2 7 = Example 2: 3 10 3 2 + 10 14 = 21 31 A bowl one contains 6 red chips and 4 blue chips, 5 of these are selected at random and put in bowl 2 which was originally empty. One chip is drawn at random from bowl 2 relative to the hypothesis that this chip is blue. Find the conditional probability that 2 red chips and 3 blue chips are transferred from bowl 1 to bowl 2. Solution: Bowl-1: 6 red and 4 blue Bowl-2: 2 red and 3 blue Let ๐ธ be the event 2 red and 3 blue chips are transferred from bowl 1 to bowl 2. Then ๐(๐ธ) = 6๐ถ 2 ×4๐ถ3 10๐ถ 5 Let ๐ต be the event that a blue chip is drawn from bowl 2. Then ๐(๐ต/๐ธ) = 3 5 ๐(๐ธ/๐ต) = ๐(๐ธ)๐(๐ต/๐ธ) ๐(๐ต) 6๐ถ 2 × 4๐ถ 3 3 × 5 1 10๐ถ 5 = ๐(๐ธ/๐ต) = 1 7 Random Variable: A random variable is a function that associates a real number with each element in the sample space. Example: Suppose that a coin is tossed twice so that the sample space is S={HH, TH, HT, TT}. Let ๐ represents the number of heads which can come up with each sample point. We can associate a number for X as: Sample point: HH ๐ : 2 TH HT TT 1 1 0 There are two types of random variables (i) Discrete Random Variable (ii) Continuous Random Variable (i) Discrete Random Variable: A Random Variable which takes on a finite (or) countably infinite number of values is called a Discrete Random Variable. (ii) Continuous Random Variable: A Random Variable which takes on non-countable infinite number of values is called as non- Discrete (or) Continuous Random Variable. Probability Mass Function (P.M.F): The set of ordered pairs (๐ฅ, ๐(๐ฅ)) is a probability function of Probability Mass Function of a Discrete Random Variable ๐ฅ. If for each possible outcome ๐ฅ, ๐(๐ฅ) must be (i) ๐(๐ฅ) ≥ 0 (ii) ∑ ๐(๐ฅ) = 1 (iii) ๐(๐ = ๐ฅ) = ๐(๐ฅ) The Probability Mass Function is also denoted by ๐๐(๐ฅ) = ๐(๐ = ๐ฅ). Probability Density Function (P.D.F): The function ๐ (๐ฅ) is a Probability Density Function for the Continuous Random Variable ๐ฅ defined over the set of real numbers ๐ , ๐๐ (i) ๐(๐ฅ) ≥ 0, ∀ ๐ฅ ∈ ๐ +∞ (ii) ∫−∞ ๐(๐ฅ) ๐๐ฅ = 1 ๐ (iii) ๐(๐ < ๐ < ๐) = ∫๐ ๐(๐ฅ) ๐๐ฅ Cumulative Distribution Function ๐ญ(๐): The Cumulative density distribution function of a discrete random variable ๐ with probability distribution function ๐(๐ฅ) as ๐น(๐ฅ) = ๐(๐ ≤ ๐ฅ) = ∑ ๐(๐ก) ๐ก≤๐ฅ Example: The Probability function of a random variable X is X 1 2 3 f(x) ½ 1/3 1/6 Find the cumulative distribution of ๐. Sol: The cumulative distribution of ๐ is X 1 2 3 f(x) ½ 5/6 1 Problem: A shipment of 8 similar computers to a retail outlet contains 3 that are defective. If a school makes a random purchase of 2 computers. Find the probability distribution are the number of defective. Sol: Let ๐ be a random variable whose values ๐ฅ at the possible number of defective computers purchased by the school then ๐ฅ maybe 0,1,2 Now, ๐(๐ = ๐ฅ = 0) = ๐(๐ = 0) = 3๐ถ0 × 5๐ถ2 10 5 = = 8๐ถ2 28 14 ๐(๐ = ๐ฅ = 1) = ๐(๐ = 1) = 3๐ถ1 × 5๐ถ1 15 = 8๐ถ2 28 = 3๐ถ2 × 5๐ถ0 3 = 28 8๐ถ2 ๐(๐ = ๐ฅ = 2) = ๐(๐ = 2) The probability distribution function of ๐ is X 0 1 2 f(x) 10/28 15/28 3/28 Problem: A random variable ๐ has density function Find (i) The constant C (ii) ๐(1 < ๐ฅ < 2) (iii) ๐(๐ ≥ 3) (iv) ๐(๐ < 1) Sol: −3๐ฅ ๐(๐ฅ) = {๐ถ๐ 0 ๐ฅ>0 ๐ฅ≤0 Given that −3๐ฅ ๐(๐ฅ) = {๐ถ๐ 0 ๐ฅ>0 ๐ฅ≤0 ∞ (i) ∫0 ๐(๐ฅ) ๐๐ฅ = 1 +∞ {๐ ๐๐๐๐ ∫ −∞ 0 ๐(๐ฅ) ๐๐ฅ = ∫ ∞ −∞ ๐(๐ฅ) ๐๐ฅ + ∫ ∫ ๐ถ๐ −3๐ฅ ๐๐ฅ = 1 0 1 ๐ถ [0 + ] = 1 3 ๐ถ = 3. 2 (ii) ∫1 3๐ −3๐ฅ ๐๐ฅ = 3[ ๐ −3๐ฅ 2 ] −3 1 ๐ −3๐ฅ =[ 2 ] −1 1 = −[๐ −6 − ๐ −3] = ๐ −3 − ๐ −6 ∞ ∞ (iii) ∫3 ๐(๐ฅ) ๐๐ฅ = ∫3 3๐ −3๐ฅ ๐๐ฅ ๐ −3๐ฅ = 3[ −3 1 = ๐ −9 0 ∞ ] = 0 + ๐ −9 3 1 +∞ (iv) ∫−∞ ๐(๐ฅ) ๐๐ฅ = ∫−∞ ๐(๐ฅ) ๐๐ฅ + ∫0 ๐(๐ฅ) ๐๐ฅ 0 ๐(๐ฅ) ๐๐ฅ } 1 = 0 + ∫0 3๐ −3๐ฅ ๐๐ฅ ๐ −3๐ฅ = 3[ Problem: 1 ] −3 0 = 1 − ๐ −3 Let ๐ be a random variable of discrete type having 4! 1 4 ๐(๐ฅ) = ( ) , ๐ฅ = 0,1,2,3,4. ๐ฅ! (4 − ๐ฅ)! 2 Check whether ๐(๐ฅ) is actual a probability density function, if so find ๐(๐ด1 ), where ๐ด1 = {0,1}. Solution: Given the sample space of random variables is ๐ = {0,1,2,3,4}. 4 ๐(๐) = ∑ ๐(๐ฅ) ๐ฅ=0 = ๐(0) + ๐(1) + ๐(2) + ๐(3) + ๐(4) 4! 1 4 4! 1 4 4! 1 4 4! 1 4 4! 1 4 ( ) + ( ) + ( ) + ( ) = ( ) + 1! 3! 2 2! 2! 2 3! 1! 2 4! 2 4! 2 1 4 = ( ) (1 + 4 + 6 + 4 + 1) = 1 2 ๐(๐) = 1 We observe that ๐(๐ฅ) is probability density function of given random variable of discrete type. If ๐ด1 = {0,1} Then ๐(๐ด1 ) = ๐(0) + ๐(1) = Problem: 4! 1 4 4! 1 4 5 ( ) + 1!3! ( 2) = 16 4! 2 Let ๐ฅ be a random variable of continuous type with probability density function ๐(๐ฅ) = { ๐ −๐ฅ , ๐๐๐ 0 < ๐ฅ < ∞ 0 ๐๐กh๐๐๐ค๐๐ ๐ Find (๐ฅ ∈ ๐ด1 ) , ๐ด1: 0 < ๐ฅ < 1. .Solution: ๐(๐ฅ) = { ๐ −๐ฅ , ๐๐๐ 0 < ๐ฅ < ∞ 0 ๐๐กh๐๐๐ค๐๐ ๐ We observe that given ๐(๐ฅ) is probability density function ∞ ∞ ∫ ๐(๐ฅ) ๐๐ฅ = 1 0 +∞ 0 +∞ ∫0 ๐ −๐ฅ ๐๐ฅ = 1 (๐ ๐๐๐๐ since ∫−∞ ๐(๐ฅ) ๐๐ฅ = ∫−∞ ๐(๐ฅ) ๐๐ฅ + ∫0 1=1 1 ๐(๐ด1) = ๐(0 < ๐ฅ < 1) = ∫ ๐ −๐ฅ ๐๐ฅ = 1 − 0 ๐(๐ฅ) ๐๐ฅ) 1 ๐ Problem: Determine the value of the constant ๐ and the distribution function of the continuous type of random variables ๐ฅ, whose p.d.f. is 0 ๐๐ฅ ๐(๐ฅ) = ๐ −๐๐ฅ + 3๐ { 0 ๐๐๐ ๐ฅ < 0 ๐๐๐ 0 ≤ ๐ฅ ≤ 1 ๐๐๐ 1 ≤ ๐ฅ ≤ 2 ๐๐๐ 2 ≤ ๐ฅ ≤ 3 ๐๐๐ ๐ฅ > 3 Solution: We know that ∞ 0 ∫ −∞ ∫ −∞ 1 2 ๐(๐ฅ) ๐๐ฅ = 1 3 ∞ ๐(๐ฅ) ๐๐ฅ + ∫ ๐(๐ฅ) ๐๐ฅ + ∫ ๐(๐ฅ) ๐๐ฅ + ∫ ๐(๐ฅ) ๐๐ฅ + ∫ ๐(๐ฅ) ๐๐ฅ = 1 0 1 1 2 2 3 3 0 + ∫ ๐๐ฅ ๐๐ฅ + ∫ ๐ ๐๐ฅ + ∫ (−๐๐ฅ + 3๐) ๐๐ฅ + 0 = 1 0 1 0 2 3 ๐ฅ2 ๐ฅ2 2 [๐ ] + [๐๐ฅ]1 + [−๐ ] + [3๐๐ฅ]32 = 1 2 2 2 1 9๐ ๐ + 2๐ − ๐ + (− + 2๐) + 9๐ − 6๐ = 1 2 2 −4๐ + 13๐ − 7๐ = 1 −11๐ + 13๐ = 1 The cumulative distribution function ๐น(๐ฅ) ๐ฅ 1 ∫ ๐๐ก ๐๐ก = ๐ฅ 1 ∫ ๐๐ก ๐๐ก + ∫ ๐ ๐๐ก = ∫ 0 ๐= 1 0 1 0 1 2 1 ๐ฅ2 1 ๐ฅ ๐๐๐ ∫ ๐ก ๐๐ก = 2 2 2 0 ๐ฅ ๐ก ๐ก ๐ฅ 1 ๐๐ก + ∫ ๐๐ก = − , ๐๐๐ 2 2 4 1 2 2 ๐ฅ ∫ ๐๐ก ๐๐ก + ∫ ๐ ๐๐ก + ∫ (−๐๐ก + 3๐) ๐๐ก 0 1 2 0≤๐ฅ≤1 1≤๐ฅ≤2 ๐ฅ 1 1 1 ๐ก2 3 = + + [− + ๐ก] 4 2 22 2 2 = 1 1 ๐ฅ2 3 + − + ๐ฅ+1−3 4 2 2 2 =− ๐น(๐ฅ) = ๐ฅ2 3 5 + ๐ฅ− ; 2≤๐ฅ≤3 2 2 4 1, ๐๐๐ ๐ฅ > 3 0 ๐ฅ2 4 ๐ฅ 1 − 2 4 ๐ฅ2 3 5 − + ๐ฅ− 4 2 2 { 1, ๐๐๐ ๐ฅ > 3 ๐๐๐ ๐๐๐ ๐๐๐ ๐๐๐ ๐ฅ<0 0≤๐ฅ≤1 1≤๐ฅ≤2 2≤๐ฅ≤3 Mathematical Expectation: Let ๐ be a random variable with probability distribution ๐(๐ฅ), then the mean or mathematical expectation of ๐ is denoted by ๐ธ(๐) and it is denoted by ๐ธ(๐) = ∑ ๐ฅ ๐(๐ฅ), where ๐is a discrete random variable +∞ ๐ธ(๐) = ∫−∞ ๐ฅ๐(๐ฅ)๐๐ฅ ,where ๐is a continuous random variable ๐ be a random variable with pdf ๐(๐ฅ) and the mean ๐, then the variance of ๐ is ๐(๐ฅ) = ๐ 2 = E[(๐ − ๐)2] = ∑(๐ − ๐)2๐(๐ฅ), where ๐is a discrete random variable +∞ ๐(๐ฅ) = ๐ 2 = ∫−∞ (๐ − ๐)2๐(๐ฅ), where ๐is a continuous random variable The positive square root of variance is a standard deviation of ๐. It is denoted by ๐(๐. ๐ท). Note: ๐ธ(๐ฅ 2) = ∑ ๐ฅ 2 ๐(๐ฅ) (discrete) +∞ ๐ธ(๐ฅ 2) = ∫−∞ ๐ฅ 2 ๐(๐ฅ) (continuous) Problem: If ๐ is a random variable whose pdf is ๐ฅ ๐ฅ = 1,2 find the mathematical expectation of ๐(๐ฅ) = { 3 0 ๐๐กh๐๐๐ค๐๐ ๐ (i) ๐ฅ (ii) ๐ฅ 2 (iii)15 − 6๐ฅ Sol: ๐ฅ , ๐ฅ = 1,2 Given ๐(๐ฅ) = {3 0, ๐๐กh๐๐๐ค๐๐ ๐ We know that ๐ธ(๐) = ∫ ๐ฅ ๐(๐ฅ) ๐๐ฅ (continuous) (i) ๐ธ(๐ฅ) = ∑2๐ฅ=1 ๐ฅ ๐(๐ฅ) (discrete) = 1 ๐(1) + 2 ๐ (2) 2 5 1 = 1( ) +2( ) = 3 3 3 (ii) ๐ธ(๐ฅ 2) = ∑2๐ฅ=1 ๐ฅ 2 ๐(๐ฅ) (discrete) = 1 ๐(1) + 4 ๐ (2) 1 2 9 = 1( ) +4( ) = = 3 3 3 3 (iii) ๐ธ(15 − 6๐ฅ) = ∑2๐ฅ=1 15 − 6๐ฅ ๐(๐ฅ) = (15 − 6(1) ) ๐(1) + (15 − 6(2) ) ๐ (2) 2 15 1 =5 = 9( ) +3( ) = 3 3 3 (since E(c) = c) Problem: If ๐ is a random variable whose pdf is ๐(๐ฅ) = {2(1 − ๐ฅ), 0 < ๐ฅ < 1 find the mathematical expectation of 0, ๐๐กh๐๐๐ค๐๐ ๐ (i) ๐ฅ (ii) ๐ฅ 2 (iii)6๐ฅ − 3๐ฅ 2 Sol: Given ๐(๐ฅ) = {2(1 − ๐ฅ), 0, 1 0<๐ฅ<1 ๐๐กh๐๐๐ค๐๐ ๐ (i) ๐ธ(๐ฅ) = ∫0 2๐ฅ (1 − ๐ฅ)๐๐ฅ 1 1 = ∫ 2๐ฅ ๐๐ฅ − ∫ 2๐ฅ 2๐๐ฅ 0 1 0 1 ๐ฅ2 ๐ฅ3 = 2 [( ) − ( ) ] 2 0 3 0 1 1 1 = 2[ − ] = 3 2 3 1 (ii) ๐ธ(๐ฅ 2) = ∫0 2๐ฅ 2 (1 − ๐ฅ)๐๐ฅ 1 1 = ∫ 2๐ฅ 2 ๐๐ฅ − ∫ 2๐ฅ 3๐๐ฅ 0 1 0 1 ๐ฅ3 ๐ฅ4 = 2 [( ) − ( ) ] 3 0 4 0 1 1 1 = 2[ − ] = 6 3 4 1 1 (iii) ๐ธ(6๐ฅ) − ๐ธ(3๐ฅ 2) = 6 ∫0 2๐ฅ (1 − ๐ฅ)๐๐ฅ − 3 ∫0 2๐ฅ 2 (1 − ๐ฅ)๐๐ฅ 1 1 = 12 ∫ (๐ฅ − ๐ฅ 2)๐๐ฅ − 6 ∫ (๐ฅ 2 − ๐ฅ 3)๐๐ฅ 0 0 1 3 1 1 = 12 [ − ] − 6 [ ] = 12 2 2 3 Problem: If ๐ is a random variable whose pdf is 1 ๐(๐ฅ) = {๐ Sol: 1 (1+๐ฅ)2 0 −∞ < ๐ฅ < ∞ ๐๐กh๐๐๐ค๐๐ ๐ , then show that ๐ธ(๐ฅ) does not exist. +∞ ๐ธ(๐ฅ) = ∫ +∞ =∫ −∞ −∞ ๐ฅ ๐(๐ฅ) ๐๐ฅ 1 ๐ฅ ๐๐ฅ ๐ (1 + ๐ฅ)2 1 +∞ 2๐ฅ = ∫ ๐๐ฅ 2๐ −∞ (1 + ๐ฅ)2 Therefore ๐ธ(๐ฅ) does not exist. = 1 (log(1 + ๐ฅ)2)+∞ −∞ 2๐ Result 1: If ๐ is a constant ๐ธ(๐) = ๐ itself. Proof: We know that +∞ ๐ธ(๐ฅ) = ∫ −∞ ๐ฅ ๐(๐ฅ) ๐๐ฅ +∞ ๐ธ(๐) = ∫ −∞ +∞ =๐∫ ๐ ๐(๐) ๐๐ ๐(๐) ๐๐ −∞ = ๐. 1 = ๐. ๐ธ(๐) = ๐ Result 2: If ๐ ๐๐๐ ๐ are constants and ๐ is a random variable with pdf ๐(๐ฅ) then (๐๐ฅ + ๐) = ๐๐ธ(๐ฅ) + ๐ . Proof: We have +∞ ๐ธ(๐๐ฅ + ๐) = ∫ +∞ =∫ −∞ = ๐๐ธ(๐ฅ) + ๐ −∞ (๐๐ฅ + ๐) ๐(๐ฅ) ๐๐ฅ +∞ ๐ ๐ฅ ๐(๐ฅ) ๐๐ฅ + ∫ −∞ = ๐๐ธ(๐ฅ) + ๐. 1 ๐ ๐(๐ฅ) ๐๐ฅ Result 3: The variance of a random variable ๐ is ๐ 2 = ๐ธ(๐ฅ 2) − ๐ 2 . Proof: Let ๐ be a random variable then variance ๐ 2 = E[(๐ − ๐)2] = ∑(๐ − ๐)2๐(๐ฅ) ๐ 2 = ∑(๐ฅ 2 + ๐ 2 − 2๐ฅ๐)๐(๐ฅ) = ∑ ๐ฅ 2๐(๐ฅ) + ∑ ๐ 2๐(๐ฅ) − ∑ 2๐ฅ๐๐(๐ฅ) = ๐ธ(๐ฅ 2) + ๐ 2 − 2๐๐ธ(๐ฅ) = ๐ธ(๐ฅ 2) + ๐ 2 − 2๐ 2 = ๐ธ(๐ฅ 2) − ๐ 2 ๐. ๐. , ๐ 2 = ๐ธ(๐ฅ 2) − ๐ 2 Try your self Find the mean and variance of a random variable whose pdf is ๐ฅ ๐(๐ฅ) = {15 0 ๐๐๐ ๐ฅ = 1,2,3,4,5. ๐๐กh๐๐๐ค๐๐ ๐ Discrete random variables ๐ฟ ๐๐๐ ๐: Joint Probability Distribution function of (๐ฟ, ๐) The set of triples (๐๐ , ๐๐ , ๐๐๐ ), ๐ = 1,2,3, . . . , ๐ ; ๐ = 1,2,3, … , ๐ is called the joint probability distribution function of (๐, ๐) and it can be represented in the form of table as follows: ๐ X ๐1 ๐1 ๐2 ๐3 ๐11 ๐12 ๐13 ๐3 ๐31 ๐32 ๐33 ๐2 . . . ๐๐ ๐๐(๐๐ ) ๐21 . . . ๐๐1 ๐∗1 ๐22 . . . ๐๐2 ๐∗2 … … ๐23 … . . . . . . ๐๐3 … ๐∗3 … ๐๐ ๐๐(๐๐ ) ๐1๐ ๐1∗ ๐3๐ ๐3∗ ๐2๐ . . . ๐๐๐ ๐∗๐ ๐2∗ . . . ๐๐∗ 1 Marginal Probability Distribution Let (๐, ๐) be a two-dimensional discrete random variable. Then the marginal probability function of the random variable ๐ is defined as ๐ ๐(๐ = ๐ฅ๐ ) = ∑ ๐๐๐ = ๐๐∗ ๐=1 The marginal probability function of the random variable ๐ is defined as ๐ ๐(๐ = ๐ฆ๐ ) = ∑ ๐๐๐ = ๐∗๐ ๐=1 The marginal distribution of ๐ is the coefficient of pairs (๐ฅ๐ , ๐๐∗ ) and of ๐ is (๐ฆ๐ , ๐∗๐ ). Conditional Probability Distribution Let (๐, ๐) be two-dimensional discrete random variable, then ๐ (๐ = ๐ฅ๐ /๐ = ๐ฆ๐ ) = ๐ (๐ = ๐ฅ๐, ๐ = ๐ฆ๐ ) ๐ (๐ = ๐ฆ๐ ) is called the conditional probability function of ๐ given ๐ = ๐ฆ๐ . = ๐๐๐ ๐ ∗๐ and ๐ (๐ = ๐ฆ๐ /๐ = ๐ฅ๐ ) = ๐ (๐ = ๐ฅ๐, ๐ = ๐ฆ๐ ) ๐(๐ = ๐ฅ๐) is called the conditional probability function of ๐ given ๐ = ๐ฅ๐ . = ๐๐๐ ๐๐∗ Problem 1: For the bivariate probability distribution of (๐, ๐) given below, find ๐(๐ ≤ 1), ๐(๐ ≤ 3),๐(๐ ≤ 1, ๐ ≤ 3 ), ๐(๐ ≤ 1/๐ ≤ 3 ) ๐๐๐ ๐(๐ ≤ 3/๐ ≤ 1 ). ๐ 1 2 3 4 5 6 0 0 0 1/32 2/32 2/32 3/32 1 1/16 1/16 1/8 1/8 1/8 1/8 2 1/32 1/32 1/64 1/64 0 2/64 X Problem 2: A random observation on a bivariate population (๐, ๐) can yield one of the following pairs of values with probabilities noted against them: For each observation pair Probability (1,1); (2,1); (3,3); (4,3) 1/20 (3,1); (4,1); (1,2); (2,2); (3,2); (4,2); (1,3); (2,3) 1/10 Find the probability that ๐ = 2 given that ๐ = 4. Also find the probability that ๐ = 2. Examine if the two events ๐ = 4 and ๐ = 2 are independent. Problem 3: The joint probability distribution of two random variables ๐ ๐๐๐ ๐ is given by: ๐(๐ = 0, ๐ = 1) = 1 , ๐(๐ 3 Find 1 3 1 3 = 1, ๐ = −1) = , ๐๐๐ ๐(๐ = 1, ๐ = 1) = . (i) Marginal distributions of ๐ ๐๐๐ ๐ (ii) the conditional probability distribution of ๐ given ๐ = 1. Try Yourself: (a) A two-dimensional random variable (๐, ๐) have a bivariate distribution given by: ๐(๐ = ๐ฅ, ๐ = ๐ฆ) = ๐ฅ2 +๐ฆ , ๐๐๐ 32 ๐ฅ = 0,1,2,3 ๐๐๐ ๐ฆ = 0,1. Find the marginal distribution of ๐ ๐๐๐ ๐ (b) a two-dimensional random variable (๐, ๐) have a joint probability mass function: ๐(๐ฅ, ๐ฆ) = 1 (2๐ฅ 27 + ๐ฆ), where ๐ฅ ๐๐๐ ๐ฆ can assume only the integer values 0,1 and 2. Find the conditional distribution of ๐ for ๐ = ๐ฅ. Continuous random variables ๐ฟ ๐๐๐ ๐: Joint Probability Density function of (๐ฟ, ๐) Let (๐, ๐) be a two-dimensional continuous random variable such that ๐ (๐ − ๐๐ ๐๐ ≤๐ ≤ ๐+ , 2 2 ๐− ๐๐ ๐๐ ≤ ๐ ≤ ๐ + ) = โฌ ๐(๐, ๐) ๐๐๐๐ 2 2 Then ๐(๐, ๐) is called the joint density function of (๐, ๐), if it satisfies the following conditions: (i) (ii) (iii) ๐(๐, ๐) ≥ 0, ๐๐๐ ๐๐๐ (๐, ๐) ∈ ๐ , where R is the range space. ∞ ∞ ∫−∞ ∫−∞ ๐(๐, ๐) ๐๐๐๐ = 1 Moreover, if (๐, ๐), (๐, ๐) ∈ ๐ , then ๐ ๐ ๐(๐ ≤ ๐ ≤ ๐, ๐ ≤ ๐ ≤ ๐) = ∫๐ ∫๐ ๐(๐, ๐) ๐๐๐๐ = 1 Marginal Probability Distribution: When (๐, ๐) be a two-dimensional continuous random variable, then the marginal density function of the random variable ๐ is defined as ∞ ๐๐ (๐ฅ) = ∫ ๐(๐ฅ, ๐ฆ) ๐๐ฆ −∞ The marginal density function of the random variable ๐ is defined as ∞ ๐๐ (๐ฆ) = ∫ ๐(๐ฅ, ๐ฆ) ๐๐ฅ −∞ Conditional Probability Distribution Let (๐, ๐) be two-dimensional continuous random variable, then ๐(๐ฅ/๐ฆ) = ๐(๐ฅ, ๐ฆ) ๐๐ (๐ฆ) is called the conditional probability function of ๐ given ๐. and, ๐(๐ฆ/๐ฅ) = is called the conditional probability function of ๐ given ๐. ๐(๐ฅ,๐ฆ) ๐๐ (๐ฅ) Problem 1: 2 2 Joint distribution of ๐ ๐๐๐ ๐ is given by ๐(๐ฅ, ๐ฆ) = 4๐ฅ๐ฆ๐ −(๐ฅ +๐ฆ ) ; ๐ฅ ≥ 0, ๐ฆ ≥ 0, test whether ๐ ๐๐๐ ๐ are independent. For the above joint distribution, find the conditional density of ๐ ๐๐๐ฃ๐๐ ๐ = ๐ฆ. Solution: 2 +๐ฆ2 ) Joint probability distribution function of ๐ ๐๐๐ ๐ is ๐(๐ฅ, ๐ฆ) = 4๐ฅ๐ฆ๐ −(๐ฅ The marginal density of ๐ is given by ; ๐ฅ ≥ 0, ๐ฆ ≥ 0 ∞ ๐๐ (๐ฅ) = ∫ ๐(๐ฅ, ๐ฆ) ๐๐ฆ 0 ∞ 2 +๐ฆ2 ) = ∫ 4๐ฅ๐ฆ๐ −(๐ฅ 0 2 = 4๐ฅ ๐ −๐ฅ ∫ = Similarly, 2 ∞ 2 ๐๐ฆ = 4๐ฅ ๐ −๐ฅ ∫ ๐ฆ ๐ −๐ฆ ๐๐ฆ ∞ 0 2 −๐ฅ 2๐ฅ ๐ ; ๐ฅ ๐ −๐ก ≥0 ๐๐ก 2 0 ∞ ๐๐ (๐ฆ) = ∫ ๐(๐ฅ, ๐ฆ) ๐๐ฅ 0 2 = 2๐ฆ ๐ −๐ฆ ; ๐ฆ ≥ 0 Since ๐๐๐(๐ฅ, ๐ฆ) = ๐๐ (๐ฅ). ๐๐ (๐ฆ),๐ ๐๐๐ ๐ are independently distributed. The conditional distribution of ๐ is given by ๐ = ๐ฆ ๐๐/๐ (๐ = ๐ฅ, ๐ = ๐ฆ) = = Problem 2: 2 4๐ฅ๐ฆ๐ −(๐ฅ +๐ฆ 2 2๐ฆ ๐ −๐ฆ 2) ๐(๐ฅ, ๐ฆ) ๐๐ (๐ฆ) 2 = 2๐ฅ ๐ −๐ฅ ; ๐ฅ ≥ 0 Suppose that two-dimensional continuous random variable (๐, ๐) has joint probability density function given by (i) (ii) 1 1 ๐(๐ฅ, ๐ฆ) = { 6๐ฅ 2๐ฆ, 0, Verify that ∫0 ∫0 ๐(๐ฅ, ๐ฆ)๐๐ฅ๐๐ฆ = 1 3 4 Find ๐ (0 < ๐ < , 1 3 0 < ๐ฅ < 1, 0 < ๐ฆ < 1 ๐๐๐ ๐๐คโ๐๐๐ < ๐ < 2) , ๐(๐ + ๐ < 1), ๐(๐ > ๐)๐๐๐ ๐(๐ < 1/๐ < 2) Solution: (i) (ii) 1 1 1 1 1 1 ๐ฆ2 1 ∫0 ∫0 ๐(๐ฅ, ๐ฆ)๐๐ฅ๐๐ฆ = ∫0 ∫0 6๐ฅ 2 ๐ฆ ๐๐ฅ๐๐ฆ = ∫0 6๐ฅ 2 | 2 | ๐๐ฅ = ∫0 3๐ฅ 2 ๐๐ฅ = 1 0 3 4 ๐ (0 < ๐ < , 1 3 3/4 1 ∫1/3 6๐ฅ 2 ๐ฆ < ๐ < 2) = ∫0 3/4 2 ∫1 0 ๐๐ฅ๐๐ฆ + ∫0 ๐๐ฅ๐๐ฆ =∫ 3/4 0 ๐(๐ + ๐ < 1) 1 =∫ ∫ 0 1 = 10 1−๐ฅ 0 ๐ฆ2 1 3 8 3/4 6๐ฅ 2 ( ) ๐๐ฅ = ∫ 3๐ฅ 2 ๐๐ฅ = 2 0 8 9 0 1 1 ๐ฆ2 1 − ๐ฅ ๐๐ฅ = ∫ 3๐ฅ 2(1 − ๐ฅ)2 ๐๐ฅ 6๐ฅ 2 ๐ฆ ๐๐ฅ๐๐ฆ = ∫ 6๐ฅ 2 ( ) 2 0 0 0 1 1 ๐ฅ 1 3 ๐ฅ ๐(๐ > ๐) = ∫ ∫ 6๐ฅ 2 ๐ฆ ๐๐ฅ๐๐ฆ = ∫ 3๐ฅ 2 (๐ฆ 2 ) ๐๐ฅ = ∫ 3๐ฅ 4 ๐๐ฅ = 0 5 0 0 0 0 ๐(๐ < 1/๐ < 2) = 1 1 ๐(๐ < 1 ∩ ๐ < 2) ๐(๐ < 2) 1 2 ๐(๐ < 1 ∩ ๐ < 2) = ∫ ∫ 6๐ฅ 2 ๐ฆ ๐๐ฅ๐๐ฆ + ∫ ∫ 0. ๐๐ฅ๐๐ฆ = 1 1 0 2 0 1 0 1 1 1 2 ๐(๐ < 2) = ∫ ∫ ๐(๐ฅ, ๐ฆ) ๐๐ฅ๐๐ฆ = ∫ ∫ 6๐ฅ 2 ๐ฆ ๐๐ฅ๐๐ฆ + ∫ ∫ 0. ๐๐ฅ๐๐ฆ = 1 0 Try yourself: 0 ๐(๐ < 1/๐ < 2) = 0 0 0 ๐(๐ < 1 ∩ ๐ < 2) =1 ๐(๐ < 2) 1 1. If ๐ ๐๐๐ ๐ are two random variables having joint density function Find (i) (ii) (iii) 1 (6 ๐(๐ฅ, ๐ฆ) = { 8 − ๐ฅ − ๐ฆ), 0, 0 ≤ ๐ฅ < 2, 2≤๐ฆ<4 ๐๐๐ ๐๐คโ๐๐๐ ๐(๐ < 1 ∩ ๐ < 3) ๐(๐ + ๐ < 3) ๐(๐ < 1/๐ < 3) 2. If ๐(๐ฅ1 , ๐ฅ2) = {4๐ฅ1 ๐ฅ2, 0 < ๐ฅ1 < 1, 0 < ๐ฅ2 < 1 is a joint p.d.f. of ๐ฅ1 and ๐ฅ2 . 0 ๐๐๐ ๐๐คh๐๐๐ 1 Then find ๐ (0 < ๐ฅ1 < , 2 1 4 < ๐ฅ2 < 1). Moments: The ๐ ๐กโ moment about the origin of a random variable ๐ denoted by ๐๐ is ๐ธ(๐ ๐ ), i.e., ๐0 = ๐ธ(๐ 0) = ๐ธ(1) = 1 ๐1 = ๐ธ(๐ 1) = ๐ธ(๐) = ๐ 2 ๐2 = ๐ธ(๐ 2 ) − (๐ธ(๐)) = ๐ธ(๐ 2 ) − ๐ 2 ๐ธ(๐ 2) = ๐ 2 + ๐ 2 Moment Generating function (MGF): The MGF of the distribution of a random variable completely describes the nature of the distribution. Let having PDF ๐(๐), then the MGF of the distribution of ๐ is denoted by ๐(๐ก) and is defined as ๐(๐ก) = ๐ธ(๐ ๐ก๐ฅ ). ∑ ๐ ๐ก๐ฅ ๐(๐ฅ) , if ๐ฅ is discrete Thus, the MGF ๐(๐ก) = { ∞ ๐ก๐ฅ ∫−∞ ๐ ๐(๐ฅ)๐๐ฅ, ๐๐ ๐ฅ ๐๐ ๐๐๐๐ก๐ข๐๐ข๐ We know that ๐(๐ก) = ๐ธ(๐ ๐ก๐ฅ ) ๐(๐ก) = ๐ธ (1 + ๐ก๐ฅ + ๐ก 2 ๐ฅ2 ๐ก 3 ๐ฅ 3 + +โฏ) 3! 2! ๐ก 2 ๐ฅ2 ๐ก 3๐ฅ 3 = ๐ธ(1) + ๐ธ(๐ก๐ฅ) + ๐ธ ( )+๐ธ( )+โฏ 2! 3! = 1 + ๐ก. ๐ธ(๐ฅ) + ๐ก2 ๐ก3 . ๐ธ(๐ฅ 2 ) + . ๐ธ(๐ฅ 3 ) + โฏ 2! 3! = 1 + ๐ก. ๐1 + ๐ก2 .๐ +โฏ 2! 2 ∞ ๐(๐ก) = ∑ ๐=0 ๐ก๐ ′ ๐ ๐! ๐ The coefficient of ๐ก๐ ๐! is about the origin is ๐๐ ′. If ๐ be a continuous random variable, then MGF is ∞ ๐(๐ก) = ∫ ๐ ๐ก๐ฅ ๐(๐ฅ)๐๐ฅ −∞ ∞ ๐ ′ (๐ก) = ∫ ๐ฅ. ๐ ๐ก๐ฅ ๐(๐ฅ)๐๐ฅ Now at ๐ก = 0 ๐ ′′ (๐ก) = −∞ ∞ ∫−∞ ๐ฅ 2 .๐ ๐ก๐ฅ ๐(๐ฅ)๐๐ฅ , … ๐(0) = ๐ธ(1) = 1 ๐ ′ (0) = ๐ธ(๐ฅ) = ๐ Mean is ๐ = ๐ ′ (0) ๐ ′′ (0) = ๐ธ(๐ฅ 2) = ๐ 2 + ๐ 2 2 Variance is ๐ ′′ (0) = ๐ ′′ (0) − (๐ ′ (0)) ๐๐ ′ = ๐๐ (๐(๐ก)) ; ๐ = 0,1,2,… ๐๐ก ๐ Example 1: Obtain the moment generating function of the probability density function is ๐(๐ฅ) = { Solution: ๐ฅ๐ −๐ฅ , 0 < ๐ฅ < ∞ . 0, ๐๐กโ๐๐๐ค๐๐ ๐ The MGF of the distribution is ๐(๐ก) = ๐ธ(๐ ๐ก๐ฅ ) ∞ ๐(๐ก) = ∫ ๐ ๐ก๐ฅ ๐(๐ฅ)๐๐ฅ ∞ −∞ = ∫ ๐ ๐ก๐ฅ ๐ฅ๐ −๐ฅ ๐๐ฅ 0 ∞ = ∫ ๐ฅ๐ (๐ก−1)๐ฅ ๐๐ฅ 0 ∞ = ∫ ๐ฅ๐ −(1−๐ก)๐ฅ ๐๐ฅ 0 = 1 , (1 − ๐ก)2 ๐๐๐ ๐ก < 1 Example 2: Find the moment generating function of the probability distribution function is 3! 1 3 , ๐ฅ = 0,1,2,3 . ๐(๐ฅ) = {๐ฅ!(3−๐ฅ)! (2) 0, ๐๐กโ๐๐๐ค๐๐ ๐ Solution: The MGF of the distribution is 3 ๐(๐ก) = ∑ ๐ ๐ก๐ฅ ๐(๐ฅ) ๐ฅ=0 3 3 = ∑ ๐ ๐ก๐ฅ ๐ฅ=0 3! 1 3 ( ) ๐ฅ! (3 − ๐ฅ)! 2 1 3! 3! 3! 3! = ( ) [ + ๐๐ก + ๐2๐ก + ๐3๐ก ] 2 3! 1! 2! 2! 1! 3! 0! 3 Characteristic function: 1 ๐(๐ก) = ( ) [1 + 3๐๐ก + 2๐2๐ก + ๐3๐ก ] 2 The characteristic function is defined as ∅๐ (๐ก) = ๐ธ(๐ ๐๐ก๐ ) = ∑ ๐ ๐๐ก๐ ๐(๐ฅ), ๐๐๐ ๐๐๐ ๐๐๐๐ก๐ ๐๐๐๐๐๐๐๐๐๐ก๐ฆ ๐๐๐ ๐ก๐๐๐๐ข๐ก๐๐๐ { ๐ฅ ∫ ๐ ๐๐ก๐ ๐(๐ฅ)๐๐ฅ, ๐๐๐ ๐๐๐๐ก๐๐๐ข๐๐ข๐ ๐๐๐๐๐๐๐๐๐๐ก๐ฆ ๐๐๐ ๐ก๐๐๐๐ข๐ก๐๐๐ If ๐น๐ (๐ฅ) is the distribution function of a continuous random variable ๐, then ∞ Where, ๐๐น(๐ฅ) = ๐ถ 1 ;๐ (1+๐ฅ2 )๐ For discrete case, we have ∅๐ (๐ก) = ∫ ๐ ๐๐ก๐ ๐๐น(๐ฅ) > 1, −∞ < ๐ฅ < ∞ −∞ ∅๐ (๐ก) = ๐ธ(๐ ๐๐ก๐ ) = ๐ธ (1 + ๐๐ก๐ + (๐๐ก)2 ๐ 2 (๐๐ก)3 ๐ฅ 3 + + โฏ) 3! 2! (๐๐ก)2 ๐ 2 (๐๐ก)3 ๐ 3 = ๐ธ(1) + ๐ธ(๐๐ก๐) + ๐ธ ( )+๐ธ( )+ โฏ 2! 3! = 1 + ๐๐ก. ๐ธ(๐) + (๐๐ก)2 (๐๐ก)3 . ๐ธ(๐ 2 ) + . ๐ธ(๐ 3 ) + โฏ 3! 2! = 1 + ๐๐ก. ๐1 + ∞ The coefficient of (๐๐ก)๐ ๐! (๐๐ก)2 . ๐2 + โฏ 2! ๐(๐ก) = ∑ ๐=0 is about the origin is ๐๐ ′. (๐๐ก)๐ ′ ๐ ๐! ๐ Properties of characteristic function: 1. If the distribution function of a random variable ๐ is symmetrical about zero, i.e., if ๐(−๐ฅ) = ๐(๐ฅ), then ∅๐ (๐ก) is real valued function of ๐ก. 2. ∅๐๐ (๐ก) = ∅๐ (๐๐ก), ๐ being a constant. 3. If ๐1 and ๐2 are independent random variables, then ∅๐1+ ๐2 (๐ก) = ∅๐1 (๐ก). ∅๐2 (๐ก) ∅๐ (๐ก) . 4. ∅๐ (−๐ก) and ∅๐ (๐ก) are conjugate functions, i.e., ∅๐ (−๐ก) = ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ Covariance: If ๐ and ๐ are two random variables, then the Covariance between them is defined as ๐ถ๐๐ฃ (๐, ๐) = ๐ธ (๐๐) − ๐ธ(๐)๐ธ(๐) Properties: 1. If ๐ and ๐ are independent random variables, then ๐ธ (๐๐) = ๐ธ (๐ )๐ธ (๐) 2. ๐ถ๐๐ฃ (๐ + ๐, ๐ + ๐ ) = ๐ถ๐๐ฃ (๐, ๐) 3. ๐ถ๐๐ฃ (๐๐ + ๐, ๐๐ + ๐ ) = ๐๐ ๐ถ๐๐ฃ (๐, ๐) Problem: Two random variables ๐ and ๐ have the following joint pdf ๐(๐ฅ, ๐ฆ) = { 2 − ๐ฅ − ๐ฆ, 0 ≤ ๐ฅ ≤ 1, 0≤๐ฆ≤1 0, ๐๐กโ๐๐๐ค๐๐ ๐ Find the i. ii. iii. Variance of ๐ Variance of ๐ Covariance of ๐ and ๐. Module-3 Correlation and Regression Correlation: In a bivariate distribution we have to find out the if there is any correlation or covariance between the two variables under study. If the change in one variable affects a change in the other variable, the variables are said to be correlated. If the two variables are deviate in the same direction, that is, if the increase (or decrease) in one result in a corresponding increase (or decrease) in the other, correlation is said to be positive. But, if they are constantly deviate in the opposite directions, that is if increase (or decrease) in one result in corresponding decrease (or increase) in the other, correlation is said to be negative. Type of Correlation: (a) Positive and Negative Correlation (b) Linear and Non-linear Correlation Covariance changes with change in scale. Correlation is independent of scale Positive and Negative Correlation: If the values of the two variables deviate in the same direction, that is, if the increase of one variable results, on an average, in a corresponding increase in the values of the other variable or if decrease in the values of one variable results, on an average, in a corresponding decrease in the values of the other variable, correlation is said to be positive or direct. Examples: ๏ง Heights and weights ๏ง Price and supply of a commodity ๏ง The family income and expenditure on luxury items, etc. On the other hand, correlation is said to be negative or inverse if the variables deviate in the opposite direction that is, if the increase or decrease in the values of one variable results, on the average, in a corresponding decrease or increase in the values of the other variable. Examples: ๏ง Price and demand of a commodity ๏ง Volume and pressure of a perfect gas, etc. Linear and Non-linear Correlation: The correlation between two variables is said to be linear if corresponding to a unit change in one variable, there is a constant change in the other variable over the entire range of the values. Example: Let us consider the following data: ๐ฅ ๐ฆ 1 2 3 4 5 5 7 9 11 13 Thus, for a c unit change in the variable of ๐ฅ, there is constant change in the corresponding values of ๐ฆ. Mathematically, the above data can be expressed by the relation ๐ฆ = 2๐ฅ + 3 In general, two variables ๐ฅ ๐๐๐ ๐ฆ are said to be linearly related, if there exists a relationship of the form ๐ฆ = ๐ + ๐๐ฅ (1) between them. From eq. (1) of straight line with slope ๐ and which makes an intercept ๐ on the ๐ฆ − ๐๐ฅ๐๐ . Hence, if the values of the two variables are plotted as points in the ๐ฅ๐ฆ − ๐๐๐๐๐. Then we get a straight line. The relationship between two variables is said to be non-linear or curvilinear if corresponding to unit change in one variable, the other variable does not change at a constant rate but at fluctuating rate. In such cases if the data are plotted on the ๐ฅ๐ฆ − ๐๐๐๐๐, we do not get a straight-line curve. Methods of studying Correlation: The methods of ascertaining only linear relationship between two variables. The commonly used methods for studying the correlation between two variables are: (a) Scatter diagram or plot method (b) Karl Pearson’s coefficient of correlation (or Covariance method) (c) Two-way frequency table (Bivariate correlation method) (d) Rank correlation method (a) Scatter diagram method: If the simplest way of the diagrammatic representation of bivariate data. Thus, for the bivariate distribution (๐ฅ๐ , ๐ฆ๐ ); ๐ = 1,2,3 … , ๐, if the values of the variables ๐ ๐๐๐ ๐ are plotted along ๐ฅ − ๐๐ฅ๐๐ and ๐ฆ − ๐๐ฅ๐๐ respectively in the ๐ฅ๐ฆ − ๐๐๐๐๐, diagram of dots so obtained is known as scatter diagram. From the scatter diagram, we can form a fairly good, whether the variables are correlated or not. For example, if the points are very dense, i.e., very close to each other, we should expect a fairly good amount of correlation is expected. This method, however, is not suitable if the number of observations is fairly large. (b) Karl Pearson’s coefficient of Correlation (Covariance method): As a measure of intensity or degree of linear relationship between two variables, Karl Pearson’s, a British Biometrician, developed a formula called Correlation coefficient. Correlation coefficient between two variables ๐ ๐๐๐ ๐, usually denoted by ๐(๐, ๐) or simply ๐๐๐ or simply ๐, is a numerical measure of linear relationship between them and is defined as: ๐๐๐ = ๐ถ๐๐ฃ(๐,๐) (1) ๐๐ ๐๐ Or It is defined as the ratio of covariance between ๐ ๐๐๐ ๐ say ๐ถ๐๐ฃ(๐, ๐) to the product of the standard deviations ๐ ๐๐๐ ๐, say ๐๐๐ = ๐ถ๐๐ฃ(๐, ๐) ๐๐ ๐๐ If (๐ฅ1 , ๐ฆ1 ), (๐ฅ2 , ๐ฆ2 ), (๐ฅ3 , ๐ฆ3 ), … , (๐ฅ๐ , ๐ฆ๐ ) are ๐ pairs of observations of the variables ๐ ๐๐๐ ๐ in a bivariate distribution, then 1 1 1 ๐ถ๐๐ฃ(๐ฅ, ๐ฆ) = ๐ ∑(๐ฅ − ๐ฅฬ )(๐ฆ − ๐ฆฬ ); ๐๐ฅ = √ ∑(๐ฅ − ๐ฅฬ )2 , ๐๐ฆ = √ ∑(๐ฆ − ๐ฆฬ )2 ๐ ๐ (2) Summation being taken over ๐ pairs of observations. 1 ∑(๐ฅ − ๐ฅฬ )(๐ฆ − ๐ฆฬ ) ๐ ๐= √1 ∑(๐ฅ − ๐ฅฬ )2 1 ∑(๐ฆ − ๐ฆฬ )2 ๐ ๐ Eq. (3) can also be written as ๐= ∑(๐ฅ−๐ฅฬ )(๐ฆ−๐ฆฬ ) √∑(๐ฅ−๐ฅฬ )2 ∑(๐ฆ−๐ฆฬ )2 ๐= Where, ๐๐ฅ = ๐ฅ − ๐ฅฬ ๐๐๐ ๐๐ฆ = ๐ฆ − ๐ฆฬ . (3) ∑ ๐๐ฅ ๐๐ฆ √∑ ๐๐ฅ 2 ∑ ๐๐ฆ 2 Example 1: Calculate Karl Pearson’s coefficient of correlation between expenditure on advertising and sales from the data given below Advertising expenses (thousands 39 65 62 90 82 75 25 98 36 78 47 53 58 86 62 68 60 91 51 84 Rs.) Sales (lakhs Rs.) Solution: Let the advertising expenses(‘000Rs.) be denoted by the variable ๐ฅ and the sales (in lakhs Rs.) be denoted by the variable ๐ฆ. We have to find the Calculation for correlation coefficient ๐ฅ 47 53 58 86 62 68 60 91 51 84 ๐๐ฅ = ๐ฅ − ๐ฅฬ = ๐ฅ − 65 -26 0 -3 25 17 10 -40 33 -29 13 ๐๐ฆ = ๐ฆ − ๐ฆฬ = ๐ฆ − 66 -19 -13 -8 20 -4 2 -6 25 -15 18 ๐๐ฅ 2 676 0 9 625 289 100 1600 1089 841 169 ๐๐ฆ 2 ๐๐ฅ๐๐ฆ ∑๐ฆ ∑ ๐๐ฅ = 0 ∑ ๐๐ฆ = 0 ∑ ๐๐ฅ 2 ∑ ๐๐ฆ 2 ∑ ๐๐ฅ๐๐ฆ ๐ฆ 39 65 62 90 82 75 25 98 63 78 ∑ ๐ฅ =650 = 660 ∑ ๐ฅฬ = ∑ ๐ฆฬ = 361 169 64 400 16 4 36 625 225 324 = 5398 ∑ ๐ฅ 650 = = 65 ๐ 10 = 2224 494 0 24 500 -68 20 240 825 435 234 = 2704 ∑ ๐ฆ 660 = = 66 ๐ 10 ๐๐ฅ = ๐ฅ − ๐ฅฬ = ๐ฅ − 65 ๐= ∑ ๐๐ฅ๐๐ฆ √∑ ๐๐ฅ 2 ∑ ๐๐ฆ 2 = ๐๐ฆ = ๐ฆ − ๐ฆฬ = ๐ฆ − 66 2704 √5398 × 2224 = 2704 √12005152 = 2704 = 0.7804 3464.8451 Hence, there is a fairly high degree of positive correlation between expenditure on advertising sales. We may, therefore conclude that in general, sales have increased with an increase in the advertising expenditures. Example 2: From the following table calculate the coefficient of correlation by Karl Pearson’s method ๐ ๐ 6 2 10 4 8 9 11 ? 8 7 Arithmetic mean of ๐ and ๐ series of 6 and 8 respectively. Solution: First of all, we shall find the missing value of ๐ . Let the missing value of ๐ series be ๐.Then the mean of ๐ฆฬ is given by: ๐ฆฬ = ∑ ๐ฆ 9 + 11 + ๐ + 8 + 7 35 + ๐ = = = 8 (๐๐๐ฃ๐๐) ๐ 5 5 35 + ๐ = 5 × 8 ๐ = 40 − 35 = 5 Now, we calculate the Correlation coefficient ๐ 6 2 10 4 8 ∑ ๐ =30 ๐ 9 11 5 8 7 ∑ ๐ =40 ๐ − ๐ฬ =๐−6 0 -4 4 -2 2 0 ๐ − ๐ฬ =๐−8 1 3 -3 0 -1 0 ๐ฬ = ๐ฬ = (๐ − ๐ฬ )2 0 16 16 4 4 ∑(๐ − ๐ฬ )2 =40 ∑ ๐ฅ 30 = =6 5 5 ∑ ๐ฆ 40 = =8 5 5 Karl Pearson’s correlation coefficient is given by (๐ − ๐ฬ )2 1 9 9 0 1 ∑(๐ − ๐ฬ )2 =20 (๐ − ๐ฬ ) (๐ − ๐ฬ ) 0 -12 -12 0 1 ∑(๐ − ๐ฬ ) (๐ − ๐ฬ ) =-26 ๐= ∑(๐ − ๐ฬ )(๐ − ๐ฬ ) ๐ถ๐๐(๐, ๐) −26 −26 −26 = = = = = −0.9192 ๐๐ฅ ๐๐ฆ √∑(๐ − ๐ฬ )2 ∑(๐ − ๐ฬ )2 √40 × 20 √800 28.2843 ๐ ≈ −0.92 Example 3: Calculate the coefficient of correlation between ๐and ๐ series from the following data Series X Y No. of series observations 15 15 Arithmetic mean 25 18 Standard deviation 3.01 3.03 Sum of squares of deviations from mean 136 138 Summation of product deviation of ๐ ๐๐๐ ๐ series from their respective arithmetic mean=122. Solution: In the usual notations, we are given ๐ = 15, ๐ฅฬ = 25, ๐ฆฬ = 18, ๐๐ฅ = 3.01, ๐๐ฆ = 3.03, ∑(๐ฅ − ๐ฅฬ )2 = 136, ∑(๐ฆ − ๐ฆฬ )2 = 138 and ∑(๐ฅ − ๐ฅฬ )(๐ฆ − ๐ฆฬ ) = 122. ๐= Example 4: ∑(๐ฅ − ๐ฅฬ )(๐ฆ − ๐ฆฬ ) 122 = = 0.8917 15 × 3.01 × 3.03 ๐ ๐๐ฅ ๐๐ฆ A computer while calculating correlation coefficient between two variables ๐ ๐๐๐ ๐ from 25 pairs of observations obtained the following results: ๐ = 25, ∑ ๐ = 125, ∑ ๐ 2 = 650, ∑ ๐ = 100, ∑ ๐ 2 = 460, ∑ ๐๐ = 508 It was, however, discovered at the time of checking that two pairs of observations were not correctly copied. They were taken as (6,14) and (8,6) while the correct values were (8,12) and (6,8). Prove that the correct value of the correlation coefficient should be 2/3. Solution: Corrected ∑ ๐ = 125 − 6 − 8 + 8 + 6 = 125 Corrected ∑ ๐ = 100 − 14 − 6 + 12 + 8 = 100 Corrected ∑ ๐ 2 = 650 − 62 − 82 + 82 + 62 = 650 Corrected ∑ ๐ 2 = 460 − 62 − 142 − 62 + 122 + 82 = 436 Corrected ∑ ๐๐ = 508 − (6 × 14) − (8 × 6) + (8 × 12) + (6 × 8) = 520 Corrected value of ๐ is given by ๐= ๐= ๐ ∑ ๐๐ − ∑ ๐ ∑ ๐ √[๐ ∑ ๐ 2 − (∑ ๐)2 ] × [๐ ∑ ๐ 2 − (∑ ๐)2 ] (25 × 520) − (125 × 100) √[25 × 520 − 1252 ] × [25 × 436 − 1002 ] Properties of correlation coefficient: = 2 3 1. Pearson coefficient cannot exceed 1 numerically. In other words, it lies between -1 and +1 i.e., −1 ≤ ๐ ≤ 1 2. Correlation coefficient is independent of the change of origin and scale. Mathematically, if X and y are the given variables and they are transformed to the new variables ๐ข ๐๐๐ ๐ฃ by the change of origin and scale ๐ข= ๐−๐ด โ ๐๐๐ ๐ฃ = ๐ฆ−๐ต ๐ , โ > 0, ๐ > 0. Where, A, B, h and k are constants, โ > 0, ๐ > 0, then the correlation between ๐ฅ ๐๐๐ ๐ฆ is same the correlation coefficient between ๐ข ๐๐๐ ๐ฃ i.e., ๐(๐ฅ, ๐ฆ) = ๐(๐ข, ๐ฃ) ๐๐ฅ๐ฆ = ๐๐ข๐ฃ ๐๐ข๐ฃ = ๐๐ข๐ฃ = ∑(๐ข − ๐ขฬ )(๐ฃ − ๐ฃฬ ) √∑(๐ข − ๐ขฬ )2 ∑(๐ฃ − ๐ฃฬ )2 ๐ ∑ ๐ข๐ฃ − (∑ ๐ข)(∑ ๐ฃ) √[๐ ∑ ๐ข2 − (∑ ๐ข)2 ] × [๐ ∑ ๐ฃ 2 − (∑ ๐ฃ)2 ] 3. Two independent variables are uncorrelated i.e., ๐๐ฅ๐ฆ = 0. ๐×๐ 4. ๐(๐๐ + ๐, ๐๐ + ๐) = |๐×๐| . ๐(๐, ๐) Example: Calculate the coefficient of correlation for the ages of husbands and wives Ages of husbands (years) Ages of wives(years) 23 18 27 22 28 23 29 24 30 25 31 26 33 28 35 29 36 30 39 32 Solution: ๐ฅ 23 27 28 29 30 31 33 35 36 39 ∑ x =311 ๐ฆ 18 22 23 24 25 26 28 29 30 32 ∑ y =257 ๐ข = ๐ฅ − 31 -8 -4 -3 -2 -1 0 2 4 5 8 ∑ ๐ข =1 ๐ฃ = ๐ฆ − 25 -7 -3 -2 -1 0 1 3 4 5 7 ∑ ๐ฃ =7 ๐ข2 64 16 9 4 1 0 4 16 28 64 ∑ u2 =203 Karl Pearson’s correlation coefficient between ๐ข and ๐ฃ is given by ๐๐ข๐ฃ = = ๐ฃ2 49 9 4 1 0 1 9 16 25 49 ∑ v 2 =163 ๐ ∑ ๐ข๐ฃ − (∑ ๐ข)(∑ ๐ฃ) √[๐ ∑ ๐ข2 − (∑ ๐ข)2 ] × [๐ ∑ ๐ฃ 2 − (∑ ๐ฃ)2 ] 10 × 179 − 1 × 7 √[10 × 203 − (1)2 ] × [10 × 163 − (7)2 ] = 1790 − 7 √[2030 − 1] × [1630 − 49] ๐ข๐ฃ 56 12 6 2 0 0 6 16 25 56 ∑ uv =179 = = = 1783 √2029 × 1581 1783 45.04 × 39.76 1783 = 0.9956 1790.79 Since Karl Pearson’s correlation coefficient (๐) is independent of change of origin, we get (c) Rank ๐๐ฅ๐ฆ = ๐๐ข๐ฃ =0.9956 Correlation method: Sometimes we come across statistical series in which the variables under consideration are not capable of quantitative measurement but can be arranged in serial order. This happens when we are dealing with qualitative characteristics (attributes) such as honesty, beauty, character, morality, etc., which cannot be measured quantitatively but can be arranged serially. In such situations Karl Pearson’s coefficient of correlation cannot be used as such. Charles Edward Spearman, a British psychologist, developed a formula in 1904 which consists in obtaining the correlation coefficient between the ranks of n individuals in the two attributes under study. Suppose we want to find if two characteristics A, say, intelligence and B, say, beauty are related or not. Both the characteristics are incapable of quantitative measurements but we can arrange a group of n individuals in order of merit (ranks) w.r.t. proficiency in the two characteristics. Let the random variables X and Y denote the ranks of the individuals in the characteristics A and B respectively. If we assume that there is no tie, i.e., if no two individuals get the same rank in a characteristic then, obviously, ๐ and ๐ assume numerical values ranging from 1 to ๐. The Pearsonian correlation coefficient between the ranks ๐ and ๐ is called the rank correlation coefficient between the characteristics ๐ด and ๐ต for that group of individuals. Spearman’s rank correlation coefficient, usually denoted by ๐ (Rho) is given by the formula ๐=1− 6 ∑ ๐2 ๐(๐2 −1) (1) Where ๐ is the difference between the pair of ranks of the same individual in the two characteristics and ๐ is the number of pairs. Computation of rank correlation coefficient: We shall discuss below the method of computing the Spearman’s rank correlation coefficient ๐ under the following situations: I. II. When actual ranks are given When ranks are not given Case I: When actual ranks are given: In this situation the following steps are involved: i. ii. iii. iv. Compute ๐, the difference of ranks. Compute ๐ 2 Obtain the sum ∑ ๐ 2 Use formula (1) to get the value of ๐. Example. The ranks of the same 15 students in two subjects ๐ด and ๐ต are given below: the two numbers within the brackets denoting the ranks of the same student in ๐ด and ๐ต respectively. (1,10), (2,7), (3,2), (4,6), (5,4), (6,8), (7,3), (8,1), (9,11), (10,15), (11,9), (12,5), (13,14), (14,12), (15,13). Use Spearman’s formula to find the rank correlation coefficient. Solution: Rank in A (x) 1 2 3 4 5 Rank in B (y) 10 7 2 6 4 ๐ =๐ฅ−๐ฆ -9 -5 1 -2 1 ๐2 81 5 1 4 1 6 7 8 9 10 11 12 13 14 15 8 3 1 11 15 9 5 14 12 13 -2 4 7 -2 -5 2 7 -1 2 2 4 16 49 4 25 4 49 1 4 4 2 ∑ ๐ =272 ∑๐ =0 Spearman’s rank correlation coefficient ๐ (Rho) is given by =1− Example: ๐ =1− 6 ∑ ๐2 ๐(๐2 − 1) 17 18 6 × 272 =1− = = 0.51 35 35 15(225 − 1) Calculate Spearman’s rank correlation coefficient between advertisement cost and sales from the following data, Advertising cost (thousands Rs.) Sales (lakhs Rs.) 39 65 62 90 82 75 25 98 36 78 47 53 58 86 62 68 60 91 51 84 Solution: Let ๐ denotes the advertising cost(‘000Rs.) and ๐ denotes the Sales (lakhs Rs.). ๐ 39 65 62 90 82 75 25 98 63 78 ๐ 47 53 58 86 62 68 60 91 51 84 Rank of ๐(๐ฅ) 8 6 7 2 3 5 10 1 9 4 Rank of ๐(๐ฆ) 10 8 7 2 5 4 6 1 9 1 ๐ =๐ฅ−๐ฆ -2 -2 0 0 -2 1 4 0 0 1 ๐2 4 4 0 0 4 1 16 0 0 1 Here ๐ = 10 Example: ∑ ๐ =0 ∑ ๐2 =30 6 ∑ ๐2 6 × 30 2 9 ๐ =1− = 1 − = 1 − = = 0.82. ๐(๐2 − 1) 10 × 99 11 11 Find the rank correlation coefficient from the following data Ranks in 1 2 3 4 5 6 7 3 1 2 6 5 7 X Ranks in 4 Y Solution: In this problem ranks are not repeated ๐ฅ 1 ๐ฆ 4 ๐๐ = ๐ฅ๐ − ๐ฆ๐ -3 ๐๐ 2 2 3 -1 1 3 1 2 4 4 2 2 4 5 6 -1 1 6 5 1 1 7 7 0 0 9 ∑ ๐๐ 2 = 20 In this problem ranks are not repeated, so the rank correlation coefficient is 6 ∑ ๐2 ๐(๐ฅ, ๐ฆ) = ๐ = 1 − ๐(๐2 − 1) =1− Example: 6 × 20 = 0.6429 7(72 − 1) Calculate the rank correlation coefficient from the following data, which give the ranks of 10 students in Mathematics and Computer Science Mathematics 1 (๐ฅ) Computer 6 Science(๐ฆ) 5 3 4 7 6 10 2 9 8 9 1 3 5 4 8 2 10 7 Solution: ๐ฅ 1 ๐ฆ 6 ๐๐ = ๐ฅ๐ − ๐ฆ๐ -5 ๐๐ 2 5 9 -4 16 3 1 2 4 4 3 1 1 7 5 2 4 6 4 2 4 10 8 2 4 2 2 0 0 9 10 -1 1 8 7 1 1 25 ∑ ๐๐ 2 =60 In this problem ranks are not repeated, so the rank correlation coefficient is ๐ =1− =1− 6 ∑ ๐2 ๐(๐2 − 1) 6 × 60 = 0.63636 10(102 − 1) Try yourself: The ranks of same 16 students in mathematics and physics are as follows. Calculate rank correlation coefficients for proficiency in mathematics and physics Mathematics 1 (๐ฅ) Physics (๐ฆ) 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 10 3 4 5 7 2 6 8 11 15 9 14 12 16 13 Example: Ten competitors in a beauty contest are ranked by three judges in the following order 1st Judge 2nd Judge 3rd Judge 1 3 6 6 5 4 5 8 9 10 4 8 3 7 1 2 10 2 4 2 3 9 1 10 7 6 5 8 9 7 Use the rank correlation coefficient to determine which pair of judges has the nearest approach in common tastes in beauty. Solution: Let ๐ 1 , ๐ 2 and ๐ 3 denote the ranks given by the first, second and third judges respectively and let ๐๐๐ be the rank correlation coefficient between the ranks given by ith and jth judges ๐ ≠ ๐ = 1,2,3. Let ๐๐๐ = ๐ ๐ − ๐ ๐ , be the difference of ranks of an individual given by the ith and jth judge. ๐ 1 1 6 5 10 3 2 4 9 7 8 ๐ 2 3 5 8 4 7 10 2 1 6 9 ๐ 3 6 4 9 8 1 2 3 10 5 7 ๐12 = ๐ 1 − ๐ 2 -2 1 -3 6 -4 -8 2 8 1 -1 ๐13 = ๐ 1 − ๐ 3 -5 2 -4 2 2 0 1 -1 2 1 ๐23 = ๐ 2 − ๐ 3 -3 1 -1 -4 6 8 -1 -9 1 2 ๐12 2 4 1 9 36 16 64 4 64 1 1 ๐13 2 25 4 16 4 4 0 1 1 4 1 ๐23 2 9 1 1 16 36 64 1 81 1 1 ∑ ๐12 =0 ∑ ๐13 =0 ∑ ๐23 =0 ∑ ๐12 2 = 200 ∑ ๐13 2 = ∑ ๐23 2 = 60 214 We have ๐ = 10 Spearman’s rank correlation coefficient ๐ is given by 6 ∑ ๐12 2 6 × 200 7 = 1− = 1 − = − = −0.2121 ๐(๐2 − 1) 10 × 99 33 ๐12 ๐13 ๐23 6 ∑ ๐13 2 6 × 60 7 = 1− =1− = = 0.6363 2 ๐(๐ − 1) 10 × 99 11 6 ∑ ๐23 2 6 × 214 49 =1− =1− =− = −0.2970 2 ๐(๐ − 1) 10 × 99 165 Since ๐13 is maximum, the pair of first and third judges has the nearest approach to common tastes in beauty. Remark, since ๐12 and ๐23 are negative, the pair of judges (1,2) and (2,3) have opposite (divergent) tastes for beauty. Case II: When ranks are not given Spearman’s rank correlation formula can also be used even if we are dealing with variables which are measured quantitatively, i.e., when the actual data but not the ranks relating to two variables are given. In such a case we shall have to convert the data into ranks. The highest (smallest) observation is given the rank 1. The next highest (next lowest) observation is given rank 2 and so on. It is immaterial in which way (descending or ascending) the ranks are assigned. However, the same approach should be followed for the all the variables under consideration. Repeated ranks: In case of attributes if there is a tie i.e., if any two or more individuals are placed together in any classification with respect to an attribute or if in case of variable data there is more than one item with the same value in either or both the series, then Spearman’s formula for calculating the rank correlation coefficient breaks down, since in this case the variables X [the ranks of individuals in characteristic A (1st series)] and Y [ the ranks of individuals in characteristic B (2nd series) do not take the values from 1 to n and consequently ๐ฅฬ ≠ ๐ฆฬ , while Spearman’s formula proving we had assumed that ๐ฅฬ = ๐ฆฬ . In this case, common ranks are assigned to the repeated items. These common ranks are the arithmetic mean of the ranks which these items should have got if they are different from each other and the next item will get the rank next to the rank used computing the common rank. For example, suppose an item is repeated at rank 4. The common rank common rank to be assigned to each item is (4+5)/2 i.e., 4.5 which is the average of 4 and 5, the ranks which these observations would have assigned if they were different. The next item will be assigned the rank 6. If an item is repeated thrice at rank 7, then the common rank to be assigned to each value will e (7+8+9)/3 i.e., 8 which is arithmetic mean of 7, 8 and 9. The ranks these observations would have got if they were different from each other. The next rank to be assigned will be 10. In the Spearman’s formula add the factor ๐(๐2 −1) 12 to ∑ ๐ 2 , where ๐ is the number of times is repeated. This correction factor is to be added for each repeated value in both the series. Problem: A psychologist wanted to compare two methods A and B of teaching. He selected a random sample of 22 students. He grouped them into 11 pairs so the students in a pair have approximately equal scores on an intelligence test. In each pair one student was taught by method A and the other by method B and examined after the course. The marks obtained by them are tabulated below: Pair 1 2 3 4 5 6 7 8 9 10 11 A 24 29 19 14 30 19 27 30 20 28 11 B 37 35 16 26 23 27 19 20 16 11 21 Find the rank correlation coefficient. Solution: In the X-series, we seen that the value 30 occurs twice. The common rank assigned to each of these values is 1.5, the arithmetic mean of 1 and 2, the ranks which these which observations would have taken if they were different. The next value 29 gets the next i.e. rank 3. Again, the value 19 occurs twice. The common rank assigned to it as 8.5, the arithmetic mean of 8 and 9 and the next value, 14 gets the rank 10. Similarly, in the y-series the value 16 occurs twice and the common rank assigned to each is 9.5, the arithmetic mean of 9 and 10, the next value, 11 gets the rank 11. X Y Rank of X Rank of Y (x) (y) d=x-y ๐2 24 37 6 1 5 25 29 35 3 2 1 1 19 16 8.5 9.5 -1 1 14 26 10 4 6 36 30 23 1.5 5 -3.5 12.25 19 27 8.5 3 5.5 30.25 27 19 5 8 -3 9 30 20 1.5 7 -5.5 30.25 20 16 7 9.5 -2.5 6.25 28 11 4 11 -7 49 11 21 11 6 5 25 ∑๐ =0 ∑ ๐ 2 = 225 Hence, we see that in the X-series the items 19 and 30 are repeated, each occurring twice and, in the Yseries in the item 16 is repeated. Thus, in each of the three cases ๐ = 2. Hence on applying the correction factor ๐(๐2 −1) 12 for each repeated item, we get ๐=1− 6[∑ ๐ 2 +2( ๐ =1− 4−1 4−1 4−1 )+2( )+2( )] 12 12 12 11(121−1) , here n=11 6 × 226.5 = 1 − 1.0225 = −0.0225 11 × 120 Problem: A sample of 12 fathers and their eldest sons have the following data about their heights in inches. Fathers 65 63 67 64 68 63 70 66 68 67 69 71 (๐ฅ) 66 68 65 69 66 68 65 71 67 68 70 Sons 68 (๐ฆ) Calculate the rank correlation coefficient. Solution: ๐2 Fathers (๐ฅ) 65 Sons (๐ฆ) 68 Rank of ๐ฅ 9 Rank of ๐ฆ 5.5 ๐ =๐ฅ−๐ฆ 3.5 12.25 63 66 11 9.5 1.5 2.25 67 68 6.5 5.5 1 1 64 65 10 11.5 -1.5 2.25 68 69 4.5 3 1.5 2.25 62 66 12 9.5 2.5 6.25 70 68 2 5.5 -3.5 12.25 66 65 8 11.5 -3.5 12.25 68 71 4.5 1 3.5 12.25 67 67 6.5 8 -1.5 2.25 69 68 3 5.5 2.5 6.25 71 70 1 2 -1 1 ∑ ๐ =0 ∑ ๐2 =72.5 Correlation factors In ๐ฅ, 68 is repeated twice, then In ๐ฅ, 67 is repeated twice, then ๐(๐2 −1) 12 ๐(๐2 −1) In ๐ฆ, 67 is repeated 4 times, then In ๐ฆ, 66 is repeated twice, then In ๐ฆ, 65 is repeated twice, then 12 12 ๐(๐2 −1) ๐ = 1− = ๐(๐2 −1) ๐(๐2 −1) Rank correlation is Linear Regression: 12 = 12 = = 2(22 −1) 12 2(22 −1) = 12 = 1 = 1 4(42 −1) 12 2(22 −1) 12 2(22 −1) 12 2 2 =5 = 1 2 1 =2 1 1 1 1 6 [∑ ๐ 2 + 2 + 2 + 5 + 2 + 2] 12(144 − 1) = 0.722 If the variables in bivariate distribution are related, will find that the points in the scatter diagram will cluster round some curve called the ‘’curve of regression’’. If the curve is a straight line, it is called the line of regression and there is said to be linear regression between the variables, otherwise regression is said to be curvilinear. The lines of regression are the line which gives to be best estimate to the value of one variable for any specific value of the other variable. Thus, the line of regression is the line of ‘best fit’ and is obtained by the principle of least squares. Let us suppose that the in the bivariate distribution (๐ฅ๐ , ๐ฆ๐ ); ๐ = 1,2,3, … , ๐; ๐ฆ is dependent variable and ๐ฅ is independent variable. Let the line of regression is the line of ๐ฆ on ๐ฅ be ๐ฆ = ๐ + ๐๐ฅ (1) Eq. (1) represents the family of straight lines for different values of the arbitrary constants ′๐′ ๐๐๐ ′๐′. The problem is to determine the ′๐′ ๐๐๐ ′๐ so that the line Eq. (1) is the line of best fit. According to the principle of the principle of least squares, we have to determine ′๐′ ๐๐๐ ′๐′. ๐ ๐ธ = ∑(๐ฆ๐ − (๐ + ๐๐ฅ๐ )) ๐=1 2 Is minimum. From the principle of maxima and minima, the partial derivatives of ๐ธ, with respect to ′๐′ ๐๐๐ ′๐′ should vanish separately, i.e., ๐ ๐๐ธ = 0 = −2 ∑(๐ฆ๐ − (๐ + ๐๐ฅ๐ )) ๐๐ ๐=1 ∑๐๐=1 ๐ฆ๐ = ๐๐ + ∑๐๐=1 ๐ฆ๐ = ๐๐ + ๐ ∑๐๐=1 ๐ฅ๐ (2) ๐ ๐๐ธ = 0 = −2 ∑ ๐ฅ๐ (๐ฅ๐ − (๐ + ๐๐ฅ๐ )) ๐๐ ๐=1 ∑๐๐=1 ๐ฅ๐ ๐ฆ๐ = ๐ ∑๐๐=1 ๐ฅ๐ + ๐ ∑๐๐=1 ๐ฅ๐ 2 Dividing on both sides to the Eq. (2) by ๐, we get ๐ฆฬ = ๐ + ๐๐ฅฬ (3) (4) Now, the line of regression of ๐ ๐๐ ๐ passes through the point (๐ฅฬ , ๐ฆฬ ). 1 ๐11 = ๐ถ๐๐ฃ(๐ฅ, ๐ฆ) = ๐ ∑๐๐=1 ๐ฅ๐ ๐ฆ๐ − ๐ฅฬ ๐ฆฬ 1 ๐ ∑๐๐=1 ๐ฅ๐ ๐ฆ๐ = ๐11 + ๐ฅฬ ๐ฆฬ ๐๐ฅ 1 ๐ 2 ๐ 1 = ∑ ๐ฅ๐ 2 − ๐ฅฬ 2 ๐ ๐=1 ∑๐๐=1 ๐ฅ๐ 2 = ๐๐ฅ 2 + ๐ฅฬ 2 Dividing Eq. (3) by ๐ and using Eqs. (5) and (6), we get Eq. (7)- Eq. (4)× ๐ฅฬ , we get (5) ๐11 + ๐ฅฬ ๐ฆฬ = ๐๐ฅฬ + ๐(๐๐ฅ 2 + ๐ฅฬ 2 ) (6) (7) ๐11 = ๐๐๐ฅ 2 ๐= ๐11 ๐๐ฅ 2 Since ‘b’ is the slope of the line of regression of Y on X and since the line of regression passes through the point (๐ฅฬ , ๐ฆฬ ) its equation is ๐ − ๐ฆฬ = ๐(๐ฅ − ๐ฅฬ ) = ๐11 (๐ − ๐ฅฬ ) ๐๐ฅ 2 ๐ − ๐ฆฬ = ๐ ๐๐ (๐ − ๐ฅฬ ) ๐๐ ๐ − ๐ฅฬ = ๐ ๐๐ (๐ − ๐ฆฬ ) ๐๐ Starting the equation ๐ = ๐ด + ๐ต๐ and proceeding similarly, we get Problem: From the following data, obtain the two regression equations Sales 91 97 108 121 67 124 51 73 111 57 Purchases 71 75 69 97 70 91 39 61 80 47 Solution: Let us denote the sales by the variable ๐ฅ ๐๐๐ ๐ฆ the purchases by the variable ๐ฆ ๐ฅ 91 97 108 121 67 124 51 73 111 ๐ฆ 71 75 69 97 70 91 39 61 80 ๐๐ฅ = ๐ฅ − 90 1 7 18 31 -23 34 -39 -17 21 ๐๐ฆ = ๐ฆ − 70 1 5 -1 27 0 21 -31 -9 10 ๐๐ฅ 2 1 49 324 961 529 1156 1521 289 441 ๐๐ฆ 2 1 25 1 729 0 441 961 81 100 ๐๐ฅ ๐๐ฆ 1 35 -18 837 0 714 1209 153 210 57 47 ∑๐ฅ ∑๐ฆ = 900 We have, ๐ฅฬ = = 700 ∑๐ฅ ๐ = 900 10 -33 -23 1089 529 759 ∑ ๐๐ฅ = 0 ∑ ๐๐ฆ = 0 ∑ ๐๐ฅ 2 ∑ ๐๐ฆ 2 ∑ ๐๐ฅ ๐๐ฆ = 90 ๐๐ฆ๐ฅ = ๐ฆฬ = = 6360 = 2868 ∑ ๐ฆ 700 = = 70 ๐ 10 ∑(๐ฅ − ๐ฅฬ )(๐ฆ − ๐ฆฬ ) ∑ ๐๐ฅ๐๐ฆ 3900 = = = 0.6132 ∑(๐ฅ − ๐ฅฬ )2 ∑ ๐๐ฅ 2 6360 ๐๐ฅ๐ฆ = ∑(๐ฅ − ๐ฅฬ )(๐ฆ − ๐ฆฬ ) ∑ ๐๐ฅ๐๐ฆ 3900 = = = 1.361 ∑(๐ฆ − ๐ฆฬ )2 ∑ ๐๐ฆ 2 2868 Equation of regression of ๐ฆ ๐๐ ๐ฅ is ๐ฆ − ๐ฆฬ = ๐๐ฆ๐ฅ (๐ฅ − ๐ฅฬ ) ๐ฆ − 70 = 0.6132(๐ฅ − 90) ๐ฆ − 70 = 0.6132 ๐ฅ − 0.613 × 90 = 0.6132 ๐ฅ − 55.188 ๐ฆ = 0.6132 ๐ฅ − 55.188 + 70 ๐ฆ = 0.6132 ๐ฅ + 14.812 Equation of regression of ๐ฅ ๐๐ ๐ฆ is ๐ฅ − ๐ฅฬ = ๐๐ฅ๐ฆ (๐ฆ − ๐ฆฬ ) ๐ฅ − 90 = 1.361(๐ฆ − 70) ๐ฅ − 90 = 1.361 ๐ฆ − 1.361 × 70 = 1.361 ๐ฆ − 95.27 ๐ฅ = 1.361 ๐ฆ − 95.27 + 90 ๐ฅ = 1.361 ๐ฆ − 5.27 ๐ 2 = ๐๐ฆ๐ฅ . ๐๐ฅ๐ฆ ๐ 2 = 0.6132 × 1.361 = 0.8346 ๐ = โ0.9135 = 3900 But since, both the regression coefficients are positive, ๐ must be positive. ๐ = 0.9135 Problem: From the data given below find (a) (b) (c) (d) Two regression coefficients The two regression equations The coefficient of correlation between the marks in Economics and Statistics The most likely marks in Statistics when marks in Economics are 30. Marks in 25 Economics Marks in 43 Statistics 28 35 32 31 36 29 38 34 32 46 49 41 36 32 31 30 33 39 Solution: ๐ฆ ๐ฅ 25 28 35 32 31 36 29 38 34 32 43 46 49 41 36 32 31 30 33 39 ∑๐ฅ ∑๐ฆ = 320 = 380 ๐๐ฅ = ๐ฅ − 32 -7 -4 3 0 -1 4 -3 6 2 0 ๐๐ฆ = ๐ฆ − 38 5 8 11 3 -2 -6 -7 -8 -5 1 ๐๐ฅ 2 ๐๐ฆ 2 ๐๐ฅ ๐๐ฆ ∑ ๐๐ฅ = 0 ∑ ๐๐ฆ = 0 ∑ ๐๐ฅ 2 ∑ ๐๐ฆ 2 ∑ ๐๐ฅ ๐๐ฆ ๐ฅฬ = (a) Regression coefficients: 49 16 9 0 1 16 9 36 4 0 = 140 ∑ ๐ฅ 320 = = 32 ๐ 10 ๐ฆฬ = ∑ ๐ฆ 380 = = 38 ๐ 10 Coefficient of regression ๐ฆ ๐๐ ๐ฅ is given by 25 64 121 9 4 36 49 64 25 1 = 398 -35 -32 33 0 2 -24 21 -48 -10 0 = −93 ๐๐ฆ๐ฅ = ๐๐ฅ๐ฆ = ∑(๐ฅ − ๐ฅฬ )(๐ฆ − ๐ฆฬ ) ∑ ๐๐ฅ๐๐ฆ −93 = = = −0.6643 ∑(๐ฅ − ๐ฅฬ )2 ∑ ๐๐ฅ 2 140 ∑(๐ฅ − ๐ฅฬ )(๐ฆ − ๐ฆฬ ) ∑ ๐๐ฅ๐๐ฆ −93 = = = −0.2337 ∑ ๐๐ฆ 2 ∑(๐ฆ − ๐ฆฬ )2 398 (b) Equations of the line of regression of ๐ฅ ๐๐ ๐ฆ is ๐ฅ − ๐ฅฬ = ๐๐ฅ๐ฆ (๐ฆ − ๐ฆฬ ) ๐ฅ − 32 = −0.2337(๐ฆ − 38) ๐ฅ − 32 = −0.2337 ๐ฆ + 38 × 0.2337 = −0.2337 ๐ฆ + 8.8806 ๐ฅ = −0.2337 ๐ฆ + 8.8806 + 32 ๐ฅ = −0.2337 ๐ฆ + 40.8806 Equation of line of regression of ๐ฆ ๐๐ ๐ฅ is ๐ฆ − ๐ฆฬ = ๐๐ฆ๐ฅ (๐ฅ − ๐ฅฬ ) ๐ฆ − 38 = −0.6643(๐ฅ − 32) ๐ฆ − 38 = −0.6643 ๐ฅ + 0.6643 × 32 = −0.6643 ๐ฅ + 0.6643 × 32 + 38 (c) Correlation coefficient: ๐ฆ = −0.6643 ๐ฅ + 59.2576 ๐ 2 = ๐๐ฆ๐ฅ . ๐๐ฅ๐ฆ ๐ 2 = (−0.6643)(−0.2337) = 0.1552 ๐ = โ0.394 Since the both regression coefficients are negative. Hence the discarding plus sign, we get ๐ = −0.394 (d) In order to estimate the most likely marks in Statistics (๐ฆ) when marks in Economics (๐ฅ) are 30, we use the line of regression of ๐ฆ ๐๐ ๐ฅ. The equation is ๐ฆ − 38 = −0.6643 (30) + 59.2576 ๐ฆ = 39.3286 Hence the most likely marks in Statistics when in Economics are 30, are 39.3286≈ 39. Problem: The following is an estimated supply regression for sugar: ๐ฆ = 0.025 + 1.5 ๐ฅ, where ๐ฆ is supply in kilos and ๐ฅ is price in rupees per kilo. (a) Interpret the coefficient of variable ๐ฅ (b) Predict the supply when supply when price is Rs. 20 per kilo (c) Given that ๐(๐ฅ, ๐ฆ) = 1, interpret the implied relationship between price and quality supplied. Solution: The regression equation of ๐ฆ (supply in kgs) on ๐ฅ (price in rupees per kg) is given to be ๐ฆ = 0.025 + 1.5 ๐ฅ = ๐ + ๐๐ฅ (say) (1) (a) The coefficients of variation ๐ฅ ๐ = 1.5 is the coefficient of regression of ๐ฆ ๐๐ ๐ฅ. It reflects the unit change in the value of ๐ฆ, for a unit change in the corresponding value of ๐ฅ. This means that if the price of sugar goes up by Re. 1 per kg, the estimated supply of sugar goes up by 1.5 kg. (b) From eq. (1), the estimated supply of sugar when its price is Rs. 20 per kg is given by ๐ฆ = 0.025 + 1.5 × 20 = 30.025 kg (c) ๐(๐ฅ, ๐ฆ) = 1 The relationship between that ๐ฅ ๐๐๐ ๐ฆ is exactly linear. i.e., all the observed values (๐ฅ, ๐ฆ) lies on straight line. Problem: Given that the regression equations of ๐ฆ ๐๐ ๐ฅ and of ๐ฅ ๐๐ ๐ฆ are respectively ๐ฆ = ๐ฅ and 4๐ฅ − ๐ฆ = 3, and that the second moment of ๐ฅ about the origin is 2, find (a) The correlation coefficient between ๐ฅ ๐๐๐ ๐ฆ (b) The standard deviation of ๐ฆ Solution: Regression equation of ๐ฆ ๐๐ ๐ฅ is ๐ฆ = ๐ฅ ๐๐ฆ๐ฅ = 1 Regression equation of ๐ฅ ๐๐ ๐ฆ is 4๐ฅ − ๐ฆ = 3 1 3 ๐ฅ= ๐ฆ+ 4 4 ๐๐ฅ๐ฆ = 1 4 (a) The correlation coefficient between ๐ฅ ๐๐๐ ๐ฆ is ๐ 2 = ๐๐ฆ๐ฅ . ๐๐ฅ๐ฆ ๐2 = 1 × 1 1 = 4 4 ๐ = โ0.5 Since the both the regression coefficients are positive ๐ = 0.5. (b) We are given that the second moment of ๐ฅ about origin is 2. i.e., ∑ ๐ฅ2 ๐ Since (๐ฅฬ , ๐ฆฬ ) is the point of intersection of the two lines of regression Solving ๐ฆ = ๐ฅ and 4๐ฅ − ๐ฆ = 3, then ๐ฅ = 1 = ๐ฆ ๐ฅฬ = 1 ๐๐๐ ๐ฆฬ = 1 Also, ๐๐ฆ๐ฅ = ๐ ๐๐ฆ ๐๐ฅ ๐๐ฅ 2 = ∑ ๐ฅ2 − ๐ฅฬ 2 = 2 − 1 = 1 ๐ 1= 1 ๐๐ฆ ( ) 2 1 ๐๐ฆ = 2 =2 Coefficient of Determination: Coefficient of correlation between two variable series is a measure of linear relationship between them and indicates the amount of variation of one variable which is associated with or accounted for by another variable. A more useful and readily comprehensible measure for this purpose is the coefficient of determination which gives the percentage variation in the dependent variable that is accounted for by the independent variable. In other words, the coefficient of determination gives the ratio of the explained variance to the total variance. The coefficient is given by the square of the correlation coefficient i.e., ๐2 = Ex: ๐๐ฅ๐๐๐๐๐๐๐ ๐ฃ๐๐๐๐๐๐๐ ๐ก๐๐ก๐๐ ๐ฃ๐๐๐๐๐๐๐ . If the value of ๐ = 0.8, we cannot conclude that 80% of the variation in the relative series (dependent variable) is due to the variation in the subject series (independent variable). But the coefficient of determination in this case ๐ 2 = 0.64 which implies that only 64% of the variation in the relative series has been explained by the subject series and the remaining 36% of the variation is due to other factors. Coefficient of Partial correlation: Sometimes the correlation between two variables ๐ฟ๐ ๐๐๐ ๐ฟ๐ may be partly due to the correlation of third variable ๐ฟ๐ with both ๐ฟ๐ ๐๐๐ ๐ฟ๐ . In such a situation, one may want to know what the correlation between ๐1 ๐๐๐ ๐2 would be if the effect of ๐3 an each of ๐1 ๐๐๐ ๐2 were eliminated. This correlation is called partial correlation and the correlation coefficient between ๐ฟ๐ ๐๐๐ ๐ฟ๐ after the linear effect of ๐ฟ๐ on each of them has been eliminated is called the partial coefficient. The partial correlation coefficient between ๐1 ๐๐๐ ๐2, usually denoted by ๐12.3 is given by ๐12.3 = Similarly, ๐12 − ๐13 ๐23 √(1 − ๐13 2 )(1 − ๐23 2 ) ๐13.2 = and ๐23.1 = ๐13 − ๐12 ๐32 √(1 − ๐12 2 )(1 − ๐32 2 ) ๐23 − ๐21 ๐31 √(1 − ๐21 2 )(1 − ๐31 2 ) Multiple correlation in terms of total and partial correlations: 1 − ๐ 1.23 ๐12 2 + ๐13 2 − 2๐12 ๐13 ๐23 =1− 1 − ๐23 2 2 1 − ๐23 2 − ๐12 2 − ๐13 2 + 2๐12 ๐13 ๐23 = 1 − ๐23 2 Note: 1 − ๐ 1.23 2 = 1 Where, ๐ = |๐21 ๐31 1 and ๐11 = | ๐32 ๐12 1 ๐32 ๐ ๐11 ๐13 ๐23 | = 1 − ๐12 2 − ๐13 2 − ๐23 2 + 2๐12 ๐13 ๐23 1 ๐23 | = 1 − ๐23 2 1 Problem: From the data relating to the yield of dry bark (๐1 ), height (๐2 ) and girth (๐3 ) for 18 cinchona plants, the following correlation coefficients were obtained: ๐12 = 0.77, ๐13 = 0.72 ๐๐๐ ๐23 = 0.52. find the partial correlation coefficients ๐12.3 and multiple correlation coefficient ๐ 1.23. Solution: ๐12.3 = ๐12 − ๐13 ๐23 √(1 − ๐13 2 )(1 − ๐23 2 ) = = 0.77 − 0.72 × 0.52 √(1 − 0.722 )(1 − 0.522 ) ๐ 1.23 2 = = 0.62 ๐12 2 + ๐13 2 − 2๐12 ๐13 ๐23 1 − ๐23 2 0.772 + 0.722 − 2 × 0.77 × 0.72 × 0.52 = 0.7334 1 − 0.522 ๐ 1.23 = +0.8564 (since multiple correlation is non-negative). Problem: In a trivariate distribution ๐1 = 2, ๐2 = ๐3 = 3, ๐12 = 0.7, ๐23 = ๐31 = 0.5. Find (i) ๐23.1 (ii) ๐ 1.23 (iii) ๐12.3 , ๐13.2 and (iv) ๐1.23 . Solution: ๐23.1 = (ii) = ๐23 − ๐21 ๐31 √(1 − ๐21 2 )(1 − ๐31 2 ) 0.5 − 0.7 × 0.5 √(1 − 0.72 )(1 − 0.52 ) ๐ 1.23 2 = ๐ 1.23 2 = = 0.2425 ๐12 2 + ๐13 2 − 2๐12 ๐13 ๐23 1 − ๐23 2 0.72 + 0.52 − 2 × 0.7 × 0.5 × 0.5 = 0.52 1 − 0.52 ๐ 1.23 = +0.7211 (iii) ๐ ๐ ๐12.3 = ๐12.3 (๐1.3 ) and ๐13.2 = ๐13.2 (๐1.2 ) 2.3 ๐12.3 = 3.2 ๐12 − ๐13 ๐23 √(1 − ๐13 2 )(1 − ๐23 2 ) (1) = 0.6 ๐13.2 = ๐13 − ๐12 ๐32 √(1 − ๐12 2 )(1 − ๐32 2 ) = 0.2425 ๐1.3= ๐1 √(1 − ๐13 2 ) = 2 × √(1 − 0.52 ) = 1.7320 ๐2.3= ๐2 √(1 − ๐23 2 ) = 3 × √(1 − 0.52 ) = 2.5980 ๐1.2= ๐1 √(1 − ๐12 2 ) = 2 × √(1 − 0.72 ) = 1.4282 ๐3.2= ๐3 √(1 − ๐32 2 ) = 2 × √(1 − 0.52 ) = 2.5980 Eq. (1) gives ๐12.3 = 0.6 × (iv) 1.7320 = 0.4 and ๐13.2 = 0.2425 × 2.5980 ๐ ๐1.23 = ๐1 (√๐ ) 1.4282 2.5980 = 0.1333 11 1 ๐ ๐ = | 21 ๐31 1 and ๐11 = | ๐32 ๐12 1 ๐32 ๐13 ๐23 | = 1 − ๐12 2 − ๐13 2 − ๐23 2 + 2๐12 ๐13 ๐23 = 0.36 1 ๐23 | = 1 − ๐23 2 = 1 − 0.52 = 0.75 1 0.36 ) = 1.3856 ๐1.23 = 2 × (√ 0.75 Multiple regression: Bivariate Regression equation: ๏ Here we try to study the linear relationship between two variables x and y. Y = a + bX = β0 + ๐ฝ1 ๐ We see that the ๐ = ๐ฝ0 is the Y intercept, ๐ = ๐ฝ1 is the slope of the linear relationship between the variable X and Y. Multivariate regression equation ๏ท ๏ท ๏ท Y = a + b1X1 + b2X2 = β0 + β1X1 + β2X2 b1 = β1 = partial slope of the linear relationship between the first independent variable and Y, indicates the change in Y for one unit change in X1. b2 = β2 = partial slope of the linear relationship between the second independent variable and Y, indicates the change in Y for one unit change in X2. Formulas for finding partial slopes: ๐1 = ๐ฝ1 = ๐2 = ๐ฝ2 = Sy= standard deviation of Y ๐๐ฆ ๐๐ฆ1 − ๐๐ฆ2 ๐12 ( ) 2 ๐1 1 − ๐12 ๐๐ฆ ๐๐ฆ2 − ๐๐ฆ1 ๐12 ( ) 2 ๐2 1 − ๐12 S1 = standard deviation of the first independent variable (X1) S2 = standard deviation of the second independent variable (X2) ry1 = bivariate correlation between Y and X1 ry2 = bivariate correlation between Y and X2 r12 = bivariate correlation between X1 and X2 Example: 1) The salary of a person in an organisation has to be regressed in terms of experience (X1) and mistakes (X2). If it is given that the values ฬ ฬ ฬ 1 = 2.7; ๐ ฬ ฬ ฬ 2 = 13.7 ๐ฬ = 3.3; ๐ ๐๐ฆ = 2.1; ๐1 = 1.5; ๐2 = 2.6 and the zero order correlations : ๐๐ฆ1 = 0.5; ๐๐ฆ2 = −0.3; ๐12 = −0.47; Find the linear regression and interpret the results. So, Similarly, Calculation of a: Interpretation: ๐1 = ๐ฝ1 = ๐๐ฆ ๐๐ฆ1 − ๐๐ฆ2 ๐12 ( ) 2 ๐1 1 − ๐12 ๐2 = ๐ฝ2 = ๐๐ฆ ๐๐ฆ2 − ๐๐ฆ1 ๐12 ( ) 2 ๐2 1 − ๐12 ๐1 = ๐ฝ1 = ๐2 = ๐ฝ2 = 2.1 0.50 − (−0.3)(−0.47) ( ) = 0.65 1.5 1 − (−0.47)2 2.1 0.30 − (0.5)(−0.47) ( ) = −0.07 2.6 1 − (−0.47)2 ฬ ฬ ฬ 1 − ๐2 ฬ ฬ ฬ ๐ = ๐ฬ − ๐1 ๐ ๐2 ฬ ฬ ฬ 1 − ๐ฝ2 ๐ ฬ ฬ ฬ 2 ๐ฝ0 = ๐ฬ − ๐ฝ1 ๐ = 3.3 − (0.65)(2.7) − (−0.07) 13.7 = 2.5 1) If a person has no experience and has not done any mistakes, he would get a salary of 2.5 units. 2) If the experience goes up by 1 unit, there would be an increment in the salary by 0.65 units. 3) If he/ she commits a mistake, then the salary would decrease by 0.07 units. Module-4 DISCRETE PROBABILITY DISTRIBUTIONS Bernoulli’s trials: Suppose, associated with random trial there is an event called ‘success’ and the complementary event is called ‘failure’. Let the probability for success be ๐ and probability for failure be ๐. Suppose the random trials are prepared ๐ times under identical conditions. These are called Bernoullian trials. Bernoulli’s Distribution: A random variable ๐ which takes two values 0 and 1 with probability ๐ ๐๐๐ ๐ respectively. That is ๐(๐ = 0) = ๐ ๐๐๐ ๐(๐ = 1) = ๐, ๐ = 1 − ๐ is called a Bernoulli’s discrete random variable. The probability function of Bernoulli’s distribution can be written as ๐(๐) = ๐ ๐ ๐ ๐−๐ = ๐ ๐ (1 − ๐)๐−๐ ; ๐ = 0,1 Note: 1. Mean of Bernoulli’s distribution discrete random variable ๐ 2. Variance of ๐ is ๐ = ๐ธ(๐) = ∑ ๐๐ . ๐(๐๐ ) = (0 × ๐) + (1 × ๐) = ๐ ๐(๐) = ๐ธ(๐ 2 ) − ๐ธ(๐)2 = ∑ ๐๐ 2 ๐(๐๐ ) − ๐ 2 = (02 × ๐) + (12 × ๐) − ๐2 = ๐ − ๐2 = ๐(1 − ๐) = ๐๐ The standard deviation is ๐ = √๐๐ Probability Binomial Distribution: Let a random experiment be performed repeatedly and let the occurrence of an event ๐ด is any trial be called success and non-occurrence ๐(๐ดฬ ), a failure (Bernoulli trial). Consider a series of ๐ independent Bernoulli trials (๐ being finite) in which the probability of success ๐(๐ด) = ๐ or ๐(๐ดฬ ) = 1 − ๐ = ๐ in any trial is constant for each trial. ๐(๐ = ๐ฅ) = ๐๐ถ๐ฅ ๐ ๐ฅ ๐ ๐−๐ฅ , ๐ฅ = 0,1,2,3, … , ๐ Since the probabilities of 0,1,2, 3,…,n successes, namely ๐ ๐ , ๐๐ถ1 ๐ ๐−1 ๐, ๐๐ถ2 ๐ ๐−2 ๐2 , … , ๐๐ are the successive terms of the Binomial expansion of (๐ + ๐)๐ , the probability distribution so obtained is called Binomial probability distribution. Definition: A random variable ๐ is said to be follow Binomial distribution denoted by B (n, p), if it assumes only non-negative values and its probability mass function is given by ๐๐ถ๐ฅ ๐ ๐ฅ ๐ ๐−๐ฅ , ๐(๐ = ๐ฅ) = { 0, Where ๐ ๐๐๐ ๐ are known as parameters. ๐ฅ = 0,1,2,3, … , ๐ ๐๐กโ๐๐๐ค๐๐ ๐ Note: ๏ง ๏ง ๏ง If ๐ is also sometimes known as the degree of the distribution ∑๐๐ฅ=0 ๐๐ถ๐ฅ ๐ ๐ฅ ๐ ๐−๐ฅ = (๐ + ๐)๐ = 1 The Binomial distribution is important not only because of its wide range applicability, but also because it gives rise to many other probability distributions. ๏ง Any variable which follows Binomial distribution is known as Binomial variate. Conditions for Binomial Experiment: The Bernoulli process involving a series of independent trials, is based on certain conditions as under: ๏ง There are only two mutually exclusive and collective exhaustive outcomes of the random variable and one of them is referred to as a success and the other as a failure. ๏ง The random experiment is performed under the same conditions for a fixed and finite (also discrete) number of times, say n. Each observation of the random variable in a random experiment is called a trial. Each trial generates either a success denoted by ๐ or ๏ง a failure denoted by ๐. The outcome (i.e., success or failure) of any trial is not affected by the outcome of any other trial. ๏ง All the observations are assumed to be independent of each of each other. This means that the probability of outcomes remains constant throughout the process. Example: To understand the Bernoulli process, consider the coin tossing problem where 3 coins are tossed. Suppose we are interested to know the probability of two heads. The possible sequence of outcomes involving two heads can be obtained in the following three ways: HHT, HTH, THH. Binomial Probability Function: In general, for a binomial random variable, ๐ the probability of success (occurrence of desired outcome) ๐ number of times in ๐ independent trials, regardless of their order of occurrence is given by the formula: ๐(๐ = ๐ ๐ ๐ข๐๐๐๐ ๐ ๐๐ ) = ๐๐ถ๐ ๐๐ ๐ ๐−๐ = where ๐! ๐๐ ๐ ๐−๐ , ๐ = 0,1,2,3, … , ๐ (๐ − ๐)! ๐! n = number of trials (specified in advance) or sample size p = probability of success q = (1 – p), probability of failure x = discrete binomial random variable r = number of successes in n trials Relationship between mean and variance: Mean of a Binomial distribution: The Binomial probability distribution is given by Mean of ๐ is ๐(๐) = ๐๐ถ๐ ๐๐ ๐ ๐−๐ ; ๐ = 0,1,2, … , ๐, ๐ ๐ ๐=0 ๐=0 ๐๐๐ ๐ − 1 − ๐ ๐ = ๐ธ(๐) = ∑ ๐ ๐(๐) = ∑ ๐ ๐๐ถ๐ ๐๐ ๐ ๐−๐ = 0 × ๐ ๐ + 1 × ๐๐ถ1 ๐๐ ๐−1 + 2 × ๐๐ถ2 ๐2 ๐ ๐−2 + 3 × ๐๐ถ3 ๐3 ๐ ๐−3 + โฏ + ๐ ๐๐ = ๐๐๐ ๐−1 + 2. ๐(๐ − 1) 2 ๐−2 ๐(๐ − 1)(๐ − 2) 3 ๐−3 ๐ ๐ + 3. ๐ ๐ + โฏ + ๐ ๐๐ 2! 3! = ๐๐ [๐ ๐−1 + (๐ − 1)๐๐ ๐−2 + (๐ − 1)(๐ − 2) 2 ๐−3 ๐ ๐ + โฏ + ๐๐−1 ] 2! = ๐๐(๐ + ๐)๐−1 = ๐๐ ๐ = ๐ธ(๐) = ๐๐ Variance of a Binomial distribution: Variance ๐(๐) = ๐ธ(๐ 2 ) − ๐ธ(๐)2 ๐ ๐ = ∑ ๐ 2 ๐(๐) − ๐ 2 ๐=0 = ∑[๐(๐ − 1) + ๐]. ๐(๐) − ๐ 2 ๐=0 ๐ ๐ ๐−๐ = ∑ ๐(๐ − 1) ๐๐ถ๐ ๐ ๐ ๐=0 = [2. ๐ + ∑ ๐ ๐(๐) − ๐ 2 ๐=0 = [2. ๐๐ถ2 ๐2 ๐ ๐−2 + 3.2. ๐๐ถ3 ๐3 ๐ ๐−3 + โฏ + ๐(๐ − 1) ๐๐ ] + ๐ − ๐ 2 ๐(๐ − 1) 2 ๐−2 ๐(๐ − 1)(๐ − 2) 3 ๐−3 ๐ ๐ + 6. ๐ ๐ + โฏ + ๐(๐ − 1) ๐๐ ] + ๐ − ๐ 2 2! 3! = ๐(๐ − 1)๐2 [๐ ๐−2 + (๐ − 2)๐๐ ๐−3 + (๐ − 2)(๐ − 3) 2 ๐−4 ๐ ๐ + โฏ + ๐๐−2 ] + ๐ − ๐ 2 2! = ๐(๐ − 1)๐2 (๐ + ๐)๐−2 + ๐ − ๐ 2 = ๐(๐ − 1)๐2 + ๐๐ − (๐๐)2 = ๐2 ๐2 − ๐๐2 + ๐๐ − ๐2 ๐2 = ๐๐ − ๐๐2 = ๐๐(1 − ๐) = ๐๐๐ ๐(๐) = ๐๐๐ Problem 1: A fair coin is tossed six times, then find the probability of getting four heads. Solution: ๐= probability of getting a head=1/2 ๐= probability of not getting a head=1/2 ๐ = 6, ๐ = 4 ๐(๐) = 6๐ถ4 ๐๐ ๐ ๐−๐ 1 4 1 2 ๐(4) = 6๐ถ4 ( ) ( ) 2 2 = 6! 1 6 15 ( ) = 64 4! 2! 2 Problem 2: The incidence of an occupational disease in an industry is such that the workers have a 20% chance of suffering from it. What is the probability that out of 6 workers chosen at random, four or more will suffer from disease? Solution: The probability of a worker suffering from disease= p=20%=0.2 The probability that of no worker suffering from disease= q=80%=0.8 The probability that four or more workers suffer from disease = ๐(๐ ≥ 4) ๐(๐ ≥ 4) = ๐(๐ = 4) + ๐(๐ = 5) + ๐(๐ = 6) = 6๐ถ4 (0.2)4 (0.8)2 + 6๐ถ5 (0.2)5 (0.8) + 6๐ถ6 (0.2)6 = 0.0175 Problem 3: Six dice are thrown 729 times. How many times do you except at least three dice to show a 5 or 6. Solution: 2 1 ๐ = probability of occurrence of 5 or 6 in one throw= 6 = 3 ๐ =1−๐=1− ๐=6 1 2 = 3 3 The probability of getting at least three dice to show a 5 or 6 ๐(๐ ≥ 3) = ๐(๐ = 3) + ๐(๐ = 4) + ๐(๐ = 5) + ๐(๐ = 6) 1 3 2 3 1 4 2 2 1 5 2 1 1 6 = 6๐ถ3 ( ) ( ) + 6๐ถ4 ( ) ( ) + 6๐ถ5 ( ) ( ) + 6๐ถ6 ( ) 3 3 3 3 3 3 3 1 233 (160 + 60 + 12 + 1) = = 6 (3) 729 The expected number of such cases in 729 times = 729 ( 233 ) = 233 729 Problem 4: If the probability of a detective bolt is 0.2, find (i) Mean and (ii) Standard deviation for the bolts in a total of 400. Solution: Given ๐ = 400, ๐ = 0.2, ๐ = 0.8 (i) (ii) Mean is ๐๐ = 400 × 0.2 = 80 Standard deviation is √๐๐๐ = √80 × 0.8 = √64 = 8 Problem 5: Find the maximum ๐ such that the probability of getting no head in tossing a fair coin ๐ times is greater than 0.1. Solution: ๐ = probability of getting a head = ½ ๐ = probability of not getting a head = 1- ½ = ½ Probability of getting no head in tossing a fair coin ๐ times is greater than 0.1 is ๐(๐ = 0) > 0.1 ๐๐ถ0 ๐0 ๐ ๐ > 0.1 ๐ ๐ > 0.1 Hence the required maximum ๐ = 3. 1 ๐ ( ) > 0.1 2 2๐ < 10, ๐กโ๐๐ ๐ > 3. Problem 6: Fit a binomial distribution to the following frequency distribution ๐ฅ ๐ 0 1 2 3 4 5 6 13 25 52 58 32 16 4 Solution: The number of trials is ๐ = 6 ๐ = ∑ ๐๐ = total frequency Mean = ∑ ๐ ๐ ๐ฅ๐ ∑ ๐๐ Mean = ๐๐ = 25+104+174+128+8+24 200 = 2.675 ๐๐ = 6๐, ๐กโ๐๐ ๐ = 2.675 = 0.446 6 ๐ = 1 − 0.446 = 0.554 Binomial distribution to be fitted is ๐(๐ + ๐)๐ = 200(0.554 + 0.446)6 = 200[6๐ถ0 (0.554)6 + 6๐ถ1 (0.554)5 (0.446) + 6๐ถ2 (0.554)4 (0.446)2 + 6๐ถ3 (0.554)3 (0.446)3 + 6๐ถ4 (0.554)2 (0.446)4 + 6๐ถ5 (0.554)1 (0.446)5 + 6๐ถ6 (0.446)6 ] = 200[0.02891 + 0.1396 + 0.2809 + 0.3016 + 0.1821 + 0.05864 + 0.007866] = 5.782 + 27.92 + 56.18 + 60.32 + 36.42 + 11.728 + 1.5732 The successive terms in the expansion give the expected or theoretical frequencies which are ๐ฅ 0 1 2 3 4 5 6 ๐ 6 28 56 60 36 12 2 (expected or theoretical frequencies) Home Work: 1. A die is tossed thrice. A success is getting 1 or 6 on a toss. Find the mean and variance of the number of successes. 2. The mean and variance of a binomial distribution are 4 and 4/3 respectively. Then find ๐(๐ ≥ 1). 3. Fit a binomial distribution to the following frequency distribution ๐ฅ ๐ 0 1 2 3 4 5 2 14 20 34 22 8 Moment Generating Function of Binomial distribution: Let ๐~๐ต(๐, ๐), then ๐(๐ก) = ๐๐ (๐ก) = ๐ธ(๐ ๐ก๐ฅ ) ๐ ๐ = ∑ ๐ ๐ก๐ฅ ๐๐ถ๐ฅ ๐ ๐ฅ ๐ ๐−๐ฅ ๐ฅ=0 = ∑ ๐๐ถ๐ฅ (๐๐ ๐ก )๐ฅ ๐ ๐−๐ฅ = (๐ + ๐๐ ๐ก )๐ ๐ฅ=0 Characteristic Function of Binomial distribution: ∅๐ (๐ก) = ๐ธ(๐ ๐๐ก๐ฅ ) ๐ ๐ = ∑ ๐ ๐๐ก๐ฅ ๐๐ถ๐ฅ ๐ ๐ฅ ๐ ๐−๐ฅ ๐ฅ=0 = ∑ ๐๐ถ๐ฅ (๐๐ ๐๐ก )๐ฅ ๐ ๐−๐ฅ = (๐ + ๐๐ ๐๐ก )๐ ๐ฅ=0 Problem: If the moment generating function of a random variable ๐ is of the form (0.4 ๐ ๐ก + 0.6)8, find the moment generating function of 3๐ + 2. Solution: Moment generating function of a random variable ๐ is ๐๐ (๐ก) = ๐ธ(๐ ๐ก๐ฅ ) = (๐ + ๐๐ ๐ก )๐ = (0.6 + 0.4 ๐ ๐ก )8 ๐ follows the Binomial distribution with ๐ = 0.4, ๐ = 0.6, ๐ = 8 MGF of 3๐ + 2 is ๐3๐+2 (๐ก) = ๐ธ(๐ ๐ก(3๐ฅ+2) ) = ๐ธ(๐ ๐ก3๐ฅ ๐ 2๐ก ) = ๐ 2๐ก ๐ธ(๐ ๐ก3๐ฅ ) = ๐ 2๐ก ๐ธ(๐ (3๐ก)๐ฅ ) = ๐ 2๐ก (0.4 ๐ 3๐ก + 0.6)8 Cumulative Binomial distribution: ๐ต(๐ฅ; ๐, ๐) = ๐(๐ ≤ ๐ฅ) = ∑ ๐ฅ ๐=0 ๐ฅ ๐ต(๐; ๐, ๐) = ∑ ๐๐ถ๐ ๐๐ ๐ ๐−๐ , ๐=0 ๐ฅ = 0,1,2,3, … , ๐ The Binomial probabilities can be obtained from cumulative distribution as follows Note: B(-1)=0 ๐ต(๐ฅ; ๐, ๐) = ๐ต(๐ฅ; ๐, ๐) − ๐ต(๐ฅ − 1; ๐, ๐) By using the Binomial table these can also be obtained. Example: The manufacture of large high-definition LCD panels is difficult, and a moderately high proportion have too many defective pixels to pass inspection. If the probability is 0.3 that an LCD panel will not pass inspection, what is the probability that 6 of 18 panels, randomly selected from production will not pass inspection? Solution: X: LCD panel not pass in inspection. n=18, p=0.30 and x=6 ๐(๐ฅ; ๐, ๐) = ๐ต(๐ฅ; ๐, ๐) − ๐ต(๐ฅ − 1; ๐, ๐) ๐(6; 18,0.30) = ๐ต(6; 18, 0.30) − ๐ต(5; 18, 0.30) = 0.7217 − 0.5344 = 0.1873 Poisson Distribution: S.D. Poisson (1837) introduced Poisson distribution as a rare distribution of rare events. i.e. The events whose probability of occurrence is very small but the no. of trials which could lead to the occurrence of the event, are very large. Ex: 1. 2. 3. 4. The no. of printing mistakes per page in a large text Number of suicides reported in a particular city Number of air accidents in some unit time Number of cars passing a crossing per minute during the busy hours of a day, etc. Definition: A random variable X taking on one of the non-negative values 0,1,2,3,4, … (i.e. which do not have a natural upper bound) with parameter λ, λ >0, is said to follow Poisson distribution if its probability mass function is given by λ๐ฅ ๐ −λ ๐(๐ฅ; λ) = ๐(๐ = ๐ฅ) = { ๐ฅ! , 0, ๐ฅ = 0,1,2,3, … ๐๐กโ๐๐๐ค๐๐ ๐ Then X is called the Poisson random variable and the distribution is known as Poisson distribution. And the Poisson parameter, λ = np>0 Conditions to follow in Poisson Distribution: ๏ท ๏ท ๏ท The no. of trials ‘n’ is very large The probability of success ‘p’ is very small λ = np is finite. Mean of Poisson distribution: ∞ ∞ ๐ฅ=0 ๐ฅ=0 ๐ = ๐ธ(๐) = ∑ ๐ฅ ๐(๐ฅ; λ) = ∑ ๐ฅ ๐ = ๐ธ(๐) = λ = np Variance of Poisson distribution: Variance ๐(๐) = ๐ธ(๐ 2 ) − ๐ธ(๐)2 λ๐ฅ ๐ −λ ๐ฅ! ∞ = ∑ ๐ฅ 2 ๐(๐ฅ; ๐) − ๐ 2 ๐ฅ=0 ๐(๐) = ๐ 2 = λ Cumulative Poisson distribution: ๐น(๐ฅ; λ) = ๐(๐ ≤ ๐ฅ) = ∑๐ฅ๐=0 ๐(๐; λ) = ∑๐ฅ๐=0 λ๐ ๐ −λ ๐! Moment generating function: ๐(๐ก) = ๐ธ(๐ ๐ก๐ ) ∞ ∅(๐ก) = ๐ธ(๐ ๐ก๐ฅ = ∑ ๐ . ๐(๐ฅ; λ) = ∑ ๐ ๐ฅ=0 Characteristic function: ๐๐ก๐ ∞ ∞ ๐(๐ก) = ๐ λ(๐ ) = ∑๐ ๐ฅ=0 ๐๐ก๐ฅ ๐ฅ=0 ๐ก −1) ∞ ๐ก๐ฅ λ๐ฅ ๐ −λ ๐ก = ๐ λ(๐ −1) ๐ฅ! . ๐(๐ฅ; λ) = ∑ ๐ ๐๐ก๐ฅ ∅(๐ก) = ๐ λ(๐ ๐ฅ=0 ๐๐ก −1) λ๐ฅ ๐ −λ ๐๐ก = ๐ λ(๐ −1) ๐ฅ! Problem 1: A hospital switch board receives an average of 4 emergency calls in a 10-minute interval. What is the probability that i. there at most 2 emergency calls in a 10-minute interval ii. there are exactly 3 emergency calls in a 10-minute interval. Solution: Mean =λ = 4 i. ๐ −λ λ๐ฅ ๐(๐ = ๐ฅ) = ๐(๐ฅ) = ๐ฅ! P(at most 2 calls) = ๐(๐ ≤ 2) = ๐(๐ = 0) + ๐(๐ = 1) + ๐(๐ = 2) = ii. = 1 1 1 + 4. + 8. ๐4 ๐4 ๐4 1 (1 + 4 + 8) = 0.2381 ๐4 1 16 P(Exactly 3 calls) = ๐(๐ = 3) = ๐ 4 . 3! = 0.1954 Problem 2: If a random variable has a Poisson distribution such that P (1) =P (2). Find i. Mean of the distribution ii. P(4) iii. ๐(๐ ≥ 1) iv. ๐(1 < ๐ < 4) Solution: ๐ −λ λ1 ๐ −λ λ2 = 1! 2! λ2 = 2λ λ = 0 or 2 But λ ≠ 0 or 2 Therefore λ = 2 Mean of the distribution is λ = 2 i. p(x) = ii. ๐ −λ λ๐ฅ ๐ฅ! ๐ −2 24 = 0.09022 p(4) = 4! ๐(๐ ≥ 1) = 1 − ๐(๐ < 1) = 1 − ๐(๐ = 0) iii. ๐ −2 20 =1− = 0.8647 0! ๐(1 < ๐ < 4) = ๐(๐ = 2) + ๐(๐ = 3) iv. = Problem 3: ๐ −2 22 ๐ −2 23 + = 0.4511 2! 3! Fit a Poisson distribution to the following data ๐ฅ ๐ 0 1 2 3 4 5 142 156 69 27 5 1 Solution: Mean = ∑ ๐ ๐ ๐ฅ๐ ∑ ๐๐ = 0+156+138+81+20+5 400 Mean of the distribution is λ = 1 =1 So, theoretical frequency for ๐ฅ successes are given by ๐ ๐(๐ฅ). ๐ ๐(๐ฅ) = 400 × ๐ −1 1๐ฅ , ๐ฅ = 0,2,3,4,5 ๐ฅ! i.e., 400 × ๐ −1 , 400 × ๐ −1 , 200 × ๐ −1 , 66.67 × ๐ −1 , 16.67 × ๐ −1 , 3.33 × ๐ −1 i.e., 147.15, 147.15, 73.58, 24.53, 6.13, 1.23 The expected frequencies are ๐ฅ Theoretical 0 1 2 3 4 5 142 156 69 27 5 1 147 147 74 25 6 1 frequency Expected frequency Problem 4: If the moment generating function of the random variable is ๐ 4(๐ ๐ก −1) , ๐๐๐๐ ๐(๐ = ๐ + ๐), where ๐ and ๐ 2 are the mean and variance of the Poisson random variable X. Solution: ๐(๐ก) = ๐ λ(๐ Mean=Variance= λ = 4 Standard deviation = √4 =2 ๐ก −1) = ๐ 4(๐ ๐ก −1) ๐(๐ = ๐ + ๐) = ๐(๐ = 4 + 2) = ๐(6) ๐(๐ = ๐ฅ) = ๐(๐ = 6) = ๐ −4 46 = 0.1042 6! Try yourself: 1. The distribution of typing mistakes committed by a typist is given below. Assuming the distribution to be Poisson, find the expected frequencies ๐ฅ 0 1 2 3 4 5 ๐ 42 33 14 6 4 1 Hypergeometric Distribution: A discrete random variable X is said to follow the hypergeometric distribution with parameters ๐, ๐ ๐๐๐ ๐, if it assumes only non-negative values and its probability mass function is given by ๐(๐ = ๐ฅ) = โ(๐; ๐, ๐, ๐) = { (๐ )(๐−๐ ) ๐ ๐−๐ (๐๐) , 0, ๐ = 0,1,2,3, … , ๐๐กโ๐๐๐ค๐๐ ๐ min(๐, ๐) Where ๐ is a positive integer, ๐ is a positive integer not exceeding ๐ and ๐ is a positive integer that is at most ๐. (Or) ๐(๐ = ๐ฅ) = โ(๐; ๐, ๐, ๐) = ๐๐ถ๐ × ๐ − ๐๐ถ๐−๐ ๐๐ถ๐ Mean and Variance of Hypergeometric Distribution: Mean is ๐ธ(๐) = ๐๐ = ๐๐ ๐ , ๐คโ๐๐๐ ๐ = Variance is ๐ฃ๐๐(๐) = ๐๐๐ = ๐ ๐ ๐๐(๐−๐)(๐−๐) N2 (๐−1) Problem 1: A batch of 10 rocker cover gaskets contains 4 defective gaskets. If we draw samples of size 3 without replacement, from the batch of 10, find the probability that a sample contains 2 defective gaskets. Also find mean and variance. Solution: ๐(๐ = ๐ฅ) = โ(๐; ๐, ๐, ๐) = Here ๐ = 10, ๐ = 4, ๐ = 3, ๐ = 2 ๐๐ถ๐ × ๐ − ๐๐ถ๐−๐ ๐๐ถ๐ ๐(๐ = 2) = โ(๐; ๐, ๐, ๐) = Mean is ๐ธ(๐) = ๐๐ = ๐๐ ๐ = 3×4 Variance is ๐ฃ๐๐(๐) = ๐๐๐ = 10 = 12 10 = 1.2 ๐๐(๐−๐)(๐−๐) Problem 2: N2 (๐−1) = 4๐ถ2 × 6๐ถ1 = 0.3 10๐ถ3 3×4(10−4)(10−3) 102 (10−1) = 0.56 In the manufacture of car tyres, a particular production process is known to yield 10 tyres with defective walls in every batch of 100 tyres produced. From a production batch of 100 tyres, a sample of 4 is selected for testing to destruction. Find i. the probability that the sample contains 1 defective tyre ii. the expectation of the number of defectives in samples of size 4 iii. the variance of the number of defectives in samples of size 4. Solution: Sampling is clearly without replacement and we use the hypergeometric distribution with ๐ = 100, ๐ = 10, ๐ = 4, ๐ = 1 i. ๐(๐ = ๐ฅ) = ๐๐ถ๐ × ๐−๐๐ถ๐−๐ ๐(๐ = ๐ฅ) = ๐๐ถ ๐ 10๐ถ1 × 100 − 10๐ถ4−1 10 × 117480 = = 0.299 ≈ 0.3 100๐ถ4 3921225 ii. The expectation of the number of defectives in samples of size 4 iii. ๐ธ(๐) = ๐๐ 4 × 10 = = 0.4 ๐ 100 The variance of the number of defectives in samples of size 4 ๐ฃ๐๐(๐) = ๐๐(๐ − ๐)(๐ − ๐) 4 × 10(100 − 10)(100 − 4) = = 0.349 N2 (๐ − 1) 1002 (100 − 1) Multinomial distribution: ๏ง This distribution can be regarded as a generalization of Binomial distribution. ๏ง When there are more than two mutually exclusive outcomes of a trial, the observations ๐ธ1 , ๐ธ2 ,…, ๐ธ๐ are ๐ mutually exclusive lead to multinomial distribution. Suppose outcomes of a trial with respective probabilities. ๏ง Th probability that ๐ธ1 occurs ๐ฅ1 times, ๐ธ2 occurs ๐ฅ2 times,… and ๐ธ๐ , occurs ๐ฅ๐ times ๐ independent observations, is given by ๐(๐ฅ1 , ๐ฅ2 , … , ๐ฅ๐ ) = ๐๐1 ๐ฅ1 ๐2 ๐ฅ2 … ๐๐ ๐ฅ๐ , ๐คโ๐๐๐ ∑ ๐ฅ๐ = ๐ ๐๐๐ ๐ is ๏ง the number of permutations of the events ๐ธ1 , ๐ธ2 , … , ๐ธ๐ . To determine ๐, we have to find the number of permutations of ๐ objects of which ๐ฅ1 are of one kind, ๐ฅ2 of another kind, …, ๐ฅ๐ of another kind ๐ ๐กโ kind, which is given by ๐= Hence ๐(๐ฅ1 , ๐ฅ2 , … ๐ฅ๐ ) = ๐! ๐! ๐ฅ1 ! ๐ฅ2 ! … ๐ฅ๐ ! ๐ ๐ฅ1 !๐ฅ2 !…๐ฅ๐ ! 1 ๐! ๐(๐ฅ1 , ๐ฅ2 , … ๐ฅ๐ ) = ๐ = ∏๐ ๐=1 ๐ฅ๐ ! ๐ฅ1 ๐2 ๐ฅ2 … ๐๐ ๐ฅ๐ , 0 ≤ ๐ฅ๐ ≤ ๐ ∏๐๐=1 ๐๐ ๐ฅ๐ (1) Which is the required probability function of the multinomial distribution. Eq. (1) is called in multinomial expansion ๐ (๐1 + ๐2 + … + ๐๐ ) , Since, the total probability is 1, we have ๐ ∑ ๐๐ = 1 ๐=1 ๐! ๐ ๐ฅ1 ๐ ๐ฅ2 … ๐๐ ๐ฅ๐ ] ๐ฅ1 ! ๐ฅ2 ! … ๐ฅ๐ ! 1 2 ∑ ๐(๐ฅ) = ∑ [ ๐ฅ ๐ฅ ๐ = (๐1 + ๐2 + … + ๐๐ ) = 1 Moments of multinomial distribution: ๐ ๐(๐ก) = ๐๐1 , ๐2 ,… ,๐๐ (๐ก1 , ๐ก2 , … , ๐ก๐ ) = ๐ธ (๐ ∑๐=1 ๐ก๐๐๐ ) Moments: = (๐1 ๐๐ก1 + ๐2 ๐๐ก2 + … + ๐๐ ๐๐ก๐ ) ๐ ๐ธ(๐๐ ) = ๐๐๐ ๐๐๐(๐๐ ) = ๐๐๐ (1 − ๐๐ ) Problem 1: Suppose we have a bowl with 10 marbles 2 red marbles, 3 green marbles, and 5 blue marbles. We randomly select 4 marbles from the bowl, with replacement. What is the probability of selecting 2 green marbles and 2 blue marbles? Solution: To solve this problem, we apply the multinomial formula. We know the following: The experiment consists of 4 trials, i.e., ๐ = 4. 4 trials produce 0 red marbles, 2 green marbles, and 2 blue marbles; i.e., ๐ฅ๐๐๐ = ๐ฅ1 = 0 , ๐ฅ๐๐๐๐๐ = ๐ฅ2 = 2 , and ๐ฅ๐๐๐ข๐ = ๐ฅ3 = 2 On any particular trial, the probability of drawing a red, green, and blue marble is 0.2, 0.3, and 0.5, respectively. i.e., ๐๐๐๐ = 0.2, ๐๐๐๐๐๐ = 0.3, ๐๐๐๐ข๐ = 0.5 The multinomial formula is ๐(๐ฅ1 , ๐ฅ2 , … ๐ฅ๐ ) = = i.e., ๐ = ๐! ๐! ∏๐๐=1 ๐ฅ๐ ! ๐ ๐ฅ1 !๐ฅ2 !๐ฅ3 ! 1 ๐ฅ1 ๐ ∏ ๐๐ ๐ฅ๐ ๐=1 ๐2 ๐ฅ2 ๐3 ๐ฅ3 4! (0.2)0 (0.3)2 (0.5)2 = 0.135 0! 2! 2! ๐ = 0.135 Thus, if we draw 4 marbles with replacement from the bowl, the probability of drawing 0 red marbles, 2 green marbles, and 2 blue marbles is 0.135. Problem 2: In India, 30% of the population has a blood type of O+, 33% has A+, 12% has B+, 6% has AB+, 7% has O-, 8% has A-, 3% has B-, and 1% has AB-. If 15 Indian citizens are chosen at random, what is the probability that 3 have a blood type of O+, 2 have A+, 3 have B+, 2 have AB+, 1 has O-, 2 have A-, 1 has B-, and 1 has AB-? Solution: ๐ = 15 trials ๐1 = 30% = 0.30 (probability of O+) ๐2 = 33% = 0.33 (probability of A+) ๐3 = 12% = 0.12 (probability of B+) ๐4 = 6% = 0.06 (probability of AB+) ๐5 = 7% = 0.07 (probability of O−) ๐6 = 8% = 0.08 (probability of A−) ๐7 = 3% = 0.03 (probability of B−) ๐8 = 1% = 0.01 (probability of AB−) ๐ฅ1 = 3 (3 O+) ๐ฅ2 = 2 (2 A+) ๐ฅ3 = 3 (3 B+) ๐ฅ4 = 2 (2 AB+) ๐ฅ5 = 1 (1 O−) ๐ฅ6 = 2 (2 A−) ๐ฅ7 = 1 (1 B−) ๐ฅ8 = 1 (1 ๐ดB−) ๐= = ๐ = 8 (8 ๐๐๐ ๐ ๐๐๐๐๐๐ก๐๐๐ ) ๐! ๐ ๐ฅ1 ๐ ๐ฅ2 ๐ ๐ฅ3 ๐ ๐ฅ4 ๐ ๐ฅ5 ๐ ๐ฅ6 ๐ ๐ฅ7 ๐ ๐ฅ8 ๐ฅ1 ! ๐ฅ2 ! ๐ฅ3 ! ๐ฅ4 ! ๐ฅ5 ! ๐ฅ6 ! ๐ฅ7 ! ๐ฅ8 ! 1 2 3 4 5 6 7 8 15! × 0.303 × 0.332 × 0.123 × 0.062 × 0.071 × 0.082 × 0.031 3! 2! 3! 2! 1! 2! 1! 1! × 0.011 ๐ = 0.000011 Discrete Bivariate Distributions: Covariance: We are often interested in the inter-relationship, or association, between two random variables. The covariance of two random variables X and Y is ๐ถ๐๐ฃ(๐, ๐) = ๐ธ(๐๐) − ๐ธ(๐)๐ธ(๐) Or ๐ถ๐๐ฃ(๐, ๐) = ๐ธ[(๐ − ๐ธ(๐))(๐ − ๐ธ(๐))] Note: Covariance is an obvious extension of variance ๐ถ๐๐ฃ(๐, ๐) = ๐๐๐(๐) Moments: 1. The moments for the Binomial Distribution: By the definition of a moment ๐๐ = ๐ธ[๐ − ๐ธ(๐)]๐ The first four central moments of the Binomial distribution are: we know that ๐0 = 1, ๐1 = 0 ๐๐๐๐ = ๐๐ ๐2 = ๐๐๐ ๐3 = ๐๐๐(๐ − ๐) ๐4 = ๐๐๐[1 + 3๐๐(๐ − 2)] 2. The moments for the Poisson Distribution: The first four central moments of the Poisson distribution are: ๐1 = 0 ๐2 = ๐ ๐3 = ๐ ๐4 = 3๐2 + ๐ Module 5 Note: Continuous Probability Distribution ∞ ๐ 1. ∫−∞ ๐(๐)๐๐ = ∫๐ 1 (๐−๐) distribution on (a, b). ๐๐ = 1, ๐ < ๐, a and b are two parameters of the uniform 2. The distribution is also known as rectangular distribution, since the curve ๐ฆ = ๐(๐ฅ) describes a rectangle over the X-axis and between the coordinates at ๐ฅ = ๐ and ๐ฅ = ๐. Uniform Distribution: A random variable ๐ is said to follow uniform distribution over an interval (a, b), if its probability density function is constant = k (say), over the entire range of X, ๐(๐) = { ๐, 0, ๐<๐<๐ ๐๐กโ๐๐๐ค๐๐ ๐ Since the total probability is always unity, we have ๐ ∫ ๐(๐)๐๐ = 1 ๐ 3. The distribution function ๐น(๐ฅ) is given by 0, 4. ๐(๐) = { ๐๐ − ∞ < ๐ < ๐ ๐−๐ ๐−๐ 1, , ๐≤๐ ≤๐ ๐<๐<∞ Since ๐น(๐) is not continuous at ๐ฅ = ๐ and ๐ฅ = ๐, it is not differentiable at these points. Thus ๐. ๐ ๐๐ ๐น(๐) = ๐(๐) = ๐ ๐๐ ′ = ∫ ๐ ๐ ๐(๐)๐๐ ∫ ๐ ๐๐ = 1 ๐ ๐ 1 ๐= (๐ − ๐) ๐ , ๐<๐ฟ<๐ ๐(๐ฟ) = {(๐ − ๐) ๐, ๐๐๐๐๐๐๐๐๐ ≠ 0 exists everywhere except the points ๐ฅ = ๐ and ๐ฅ = Moments: ๐ ๐(๐ − ๐) = 1 1 (๐−๐) In particular, = ๐ ๐๐+1 − ๐ ๐+1 1 1 ∫ ๐ ๐ ๐๐ = [ ] ๐+1 (๐ − ๐) ๐ (๐ − ๐) Mean=๐๐ ′ = ๐2 ′ = ๐+๐ ๐ 1 2 (๐ + ๐๐ + ๐ 2) 3 ๐๐๐๐๐๐๐๐ = ๐๐ = ๐๐ ′ − (๐๐ ′)๐ = (๐ − ๐)๐ ๐๐ A random variable X is said to have a normal distribution, if its density function or probability Normal probability distribution: distribution is given by Probability density or distribution function (PDF): Let ๐ be a continuous random variable, then the probability density function of ๐ is a function of ๐(๐) such that for any two numbers ๐ ๐๐๐ ๐ with ๐ ≤ ๐. ๐ ๐(๐ ≤ ๐ ≤ ๐) = ∫๐ ๐(๐)๐๐ ๐(๐ฅ; ๐, ๐) = 1 ๐√2๐ ๐ −(๐ฅ−๐)2 2๐2 , −∞ < ๐ฅ < ∞, −∞ < µ < ∞, σ > 0. Where, ๐ is the mean and ๐ is the standard deviation of ๐ฅ. ๏ง As can be seen, the function, called probability density function of the normal distribution, depends on two values ๐ and ๐. These are referred as the two parameters of the normal distribution. ๏ง The curve has maximum value at ๐ and tapers off on either side but never touches the horizontal line. ๏ง The curve on the left side goes up to −∞, and on the right side it goes up to +∞. However, as much as 99.73% of the area under the curve lies between (µ − 3๐) and ๏ง Cumulative distribution function (CDF): (µ + 3๐) and only 0.277% of the area lies beyond these points. The random variable x is then said to a normal random variable or normal variate. The curve representing the normal distribution is called the normal curve and the total area ๐ฅ ๐น(๐) = ๐(๐ ≤ ๐ฅ) = ∫ ๐(๐ฆ)๐๐ฆ −∞ bounded by the curve and the x -axis is one. i.e., ∫ ๐(๐ฅ)๐๐ฅ = 1 ๐(๐ ≤ ๐ ≤ ๐) = ๐น(๐) − ๐น(๐) Normal distribution is applicable in the following situations: 1. Life of items subjected to wear and tear like tyres, batteries, bulbs, currency notes, etc. Normal Distribution: 2. Length and diameter of certain products like pipes, screws and discs. 3. Height and weight of baby at birth. 4. Aggregate marks obtained by students in an examination. ∞ µ= ∫−∞ ๐ฅ ๐(๐ฅ)๐๐ฅ 5. Weekly sales of an item in store. put z = Standard Normal Distribution: normal distribution with mean µ and s.d. σ, the variable z defined as z= µ= 1 µ= ๐ √2๐ 1 √2๐ here, z๐ −๐ง2 2 µ= 0 + ๐ฅ−µ ๐ µ= has standard normal distribution with mean 0 and s.d. as 1. This is also referred as z-score. Uses of Normal distribution: ๐ ๐๐ฅ Distribution. The random variable that follows this distribution is denoted by z. If a variable x follows ๐ฅ−๐ dz = The Normal Distribution with mean (µ) =0 and S.D. (σ)=1, is known as Standard Normal ๐ −๐ง2 2 ∞ = ∫−∞ ๐ √2๐ 1 ๐√2๐ ๐ −(๐ฅ−๐)2 2๐2 => ๐z+ b= x ∞ ∫−∞(๐z+ b)๐ ∞ ∫−∞(๐z)๐ −๐ง2 2 −๐ง2 2 ๐๐ฅ. ๐๐ง. ๐๐ง + 2. It has extensive use in sampling theory. It helps us to estimate parameter from statistic 1 √2๐ ∞ ∞ ∫−∞(๐)๐ ∫−∞ ๐ −๐ง2 2 −๐ง2 2 ๐๐ง. ∞ ๐๐ ๐๐ฃ๐๐ ๐๐ข๐๐๐ก๐๐๐ ๐ ๐ ∫−∞ ๐ µ= −๐ง2 2 ๐๐ง. 2๐ −๐ง2 2 ∞ ∞ 2๐ √2๐ −๐ง2 2 −๐ง2 2 2 ∞ −๐ง µ= b ๐๐ง. −๐ง2 2 x√ ๐ ๐๐ง ๐๐ง = 0 ๐๐ง = 2∫0 ๐ ∫0 ๐ √2๐ 3. It has a wide use in testing Statistical Hypothesis and Tests of significance in which it is 4. It serves as a guiding instrument in the analysis and interpretation of statistical data. ∞ ๐๐ ๐๐๐ ๐๐ข๐๐๐ก๐๐๐ ๐ ๐ ∫−∞(z)๐ µ= and to find confidence limits of the parameter. have normal distribution. ∞ ∫−∞(๐)๐ √2๐ We know that, ∫0 ๐ 1. The Normal distribution can be used to approximate Binomial and Poisson distributions. always assumed that the population from which the samples have been drawn should 1 2 ๐๐ง = √ ๐๐ง ๐ 2 2 Variance of N.D: ∞ ๐๐2 = ๐๐๐(๐) = ∫ (๐ − ๐)2๐๐ = ๐ธ[(๐ − ๐)2] −∞ Mean of Normal Distribution: Consider the Normal Distribution with b, σ as the parameters. Then f(x; b, σ ) = 1 ๐√2๐ ๐ −(๐ฅ−๐)2 2๐2 The mean µ= E(X) is given by Let ๐ has a normal distribution i.e., ๐~๐(๐, ๐ 2) with mean ๐ and standard deviation ๐, we can standardize to a standard normal random variable ๐= ๐−๐ ๐ Exponential Probability Distribution: A continuous random variable ๐ is said to follow an exponential distribution with parameter = ๐ −๐(๐ +๐ก) = ๐ −๐ ๐ก = ๐(๐ > ๐ ) ๐ −๐๐ก Therefore, exponential distribution possesses memoryless property. ๐ > 0, if its probability density function is given by Problem 1: The general form of the exponential distribution is If ๐ has an exponential distribution with mean is 2, find ๐(๐ < 1/ ๐ < 2). 1 ๐๐ −๐๐ฅ , ๐ฅ≥0 ๐(๐ฅ) = { 0, ๐๐กโ๐๐๐ค๐๐ ๐ ๐ฅ − ๐ Solution: ๐(๐ฅ) = ๐ , ๐ > 0, ๐ฅ ≥ 0 with parameter ๐. ๐ Mean of the exponential distribution is Momentum generating Function (MGF) of Exponential Distribution: The MGF is ๐๐(๐ก) = Mean = 1 ๐ Variance= 1 Mean = = 2 ๐ ๐ ๐−๐ก The probability density function is The cumulative distribution function is ๐ฅ ๐ฅ ๐น(๐ฅ) = ๐(๐ ≤ ๐ฅ) = ∫ ๐(๐ฅ)๐๐ฅ = ∫ 0 1 − ๐ −๐๐ฅ , ๐น(๐ฅ) = { 0, 0 ๐๐ −๐๐ฅ ๐๐ฅ ๐ฅ≥0 ๐ฅ<0 =1 ๐(๐ < 1/ ๐ < 2) = − ๐ −๐๐ฅ 1 ∞ ๐(๐ > ๐ + ๐ก/ ๐ > ๐ก) = 1 −∞ 0 0 0 ๐ฅ ๐(๐ < 1) ๐(๐ < 2) 2 ๐ −0.5 − 1 ] = 0.393 4 −0.5 ๐(๐ < 2) = ∫ ๐(๐ฅ)๐๐ฅ = ∫ 0.5๐ −0.5๐ฅ ๐๐ฅ = 0.5 [ ๐(๐ > ๐ + ๐ก /๐ > ๐ก) = ๐(๐ > ๐ ), for any ๐ , ๐ก > 0 ๐๐ −๐๐ฅ , ๐(๐ฅ) = { 0, = ๐(๐ < 1 ∩ ๐ < 2) ๐(๐ < 2) ๐(๐ < 1) = ∫ ๐(๐ฅ)๐๐ฅ = ∫ 0.5๐ −0.5๐ฅ ๐๐ฅ = 0.5 [ Exponential Distribution possesses memoryless property: ๐(๐ > ๐) = ∫๐ ๐๐ −๐๐ฅ ๐๐ฅ = ๐ −๐๐ 1 = 0.5 2 ๐(๐ฅ) = ๐๐ −๐๐ฅ = 0.5๐ −0.5 ๐ฅ , ๐ฅ ≥ 0 1 ๐2 The probability density function of ๐ is ๐= ๐ฅ≥0 ๐ฅ<0 ๐(๐ > ๐ + ๐ก ∩ ๐ > ๐ก) ๐(๐ > ๐ + ๐ก) = ๐(๐ > ๐ก) ๐(๐ > ๐ก) ๐(๐ < 1/๐ < 2) = 0.3934 0.6321 = 0.6223 ๐ −1 − 1 ] = 0.6321 −0.5 Problem 2: The time (in hours) required to repair a watch is exponentially distributed with parameter ๐ = i. What is the probability that the repair the time exceeds 2 hours? ii. What is the probability that a repair takes 11 hours given that duration exceeds 8 hours? 1 2 with mean 120 days, find the probability that such a watch iii. Will have to set in less than 24 days, and iv. Not have to reset in a least 180 days. ii. Solution: Let ๐ be the random variable which denotes the time to repair the machine. Then the density Solution: Let ๐ be the random variable which denotes the time to repair the watch. The probability density function of the exponential distribution is Given that ๐ = i. ii. ๐๐ ๐(๐ฅ) = { 0, 1 2 ∞1 ๐(๐ > 2) = ∫2 2 1 −๐๐ฅ ๐(๐ฅ) = ๐๐ −๐๐ฅ ๐ −2๐ฅ๐๐ฅ = ๐ −1 Exceed 5 hours , function of ๐ is given by ๐ฅ≥0 ๐ฅ<0 1 1 = ๐ −2๐ฅ , ๐ฅ ≥ 0 2 i. ii. ∞1 ๐(๐ > 2) = ∫2 2 ∞1 ๐(๐ > 5) = ∫5 2 ๐(๐ฅ) = ๐๐ −๐๐ฅ = 1 ๐ −2 ๐ฅ๐๐ฅ = ๐ −1 1 1 −1๐ฅ ๐ 2 , 2 ๐ฅ>0 5 ๐ −2 ๐ฅ๐๐ฅ = ๐ −2 = 0.082 Try yourself: Using the memoryless property, we have ๐(๐ > 3) = ∞ 1 −1๐ฅ ∫3 2 ๐ 2 ๐๐ฅ ๐(๐ ≥ 11/ ๐ > 8) = ๐(๐ > 3) = ๐ −1.5 Problem 4: A component has an exponentially time of failure distribution with mean 10,000 hours i. In the second case, given Mean=120 i.e., Mean = 1 ๐ The component has already been in operation for its mean life. What is the probability that it will fail by 15,000 hours? = 120 ii. 1 ๐= 120 At 15,000 hours the component is still in operation life. What is the probability that it operates for another 5,000 hours? The probability density function is given by iii. iv. ๐(๐ฅ) = ๐๐ −๐๐ฅ = 24 1 ๐(๐ < 24) = ∫0 120 ∞ ๐(๐ > 180) = ∫180 1 1 − 1 ๐ฅ ๐ 120 , ๐ฅ ≥ 0 120 ๐ −120 ๐ฅ ๐๐ฅ = 1 − ๐ −0.2 = 0.1813 1 120 1 ๐ −120 ๐ฅ ๐๐ฅ = ๐ −1.5 = 0.2231 Problem 3: The time line in hours required to repair a machine is exponentially distributed with parameter 1 ๐ = . What is the probability that the required time 2 i. Exceeds 2 hours Problem 5: The mileage which car owners get with certain kind of radial tyre is a random variable having an exponential distribution with mean 40,000 km. Find the probabilities that one of these tyres will last i. At least 20,000 km ii. At most 30,000 km. Problem 1: Gamma Distribution: The lifetime (in hours) of a certain piece of equipment is a continuous random variable having A continuous random variable ๐ is said to follow general Gamma distribution with two parameters ๐ > ๐ and ๐ > ๐, if its probability density function is given by ๐๐ ๐๐−๐ ๐−๐๐ ,๐ ≥ ๐ ๐(๐) = { ๐ช(๐) ๐, ๐๐๐๐๐๐๐๐๐ Note: 1. When ๐ = ๐, the distribution is called exponential distribution ∞ ∞ 2. ∫−∞ ๐(๐ฅ)๐๐ฅ = 1 (Since, ∫0 ๐ฅ ๐−1๐ −๐๐ฅ ๐๐ฅ = Γ(๐) ๐๐ ) range 0 < ๐ฅ < ∞ and the PDF is ๐(๐ฅ) = { evaluate the probability that the lifetime exceeds 2 hours. Solution: Let ๐ denote the lifetime of a certain piece of equipment with PDF 0<๐ฅ<∞ ๐ฅ๐ −๐๐ฅ , 0, ๐๐กโ๐๐๐ค๐๐ ๐ ∞ ∫ ๐(๐ฅ)๐๐ฅ = 1 −∞ ∞ Using 0 0 ∫ ๐ฅ ๐−1๐ −๐๐ฅ ๐๐ฅ = 0 ๐๐ ๐ฅ ๐−1๐ −๐๐ฅ ,๐ฅ ≥ 0 Γ(๐) 0, ๐๐กโ๐๐๐ค๐๐ ๐ Mean = ๐ ๐ Variance = ๐ ๐๐ Γ(๐) ๐๐ Γ(2) =1 ๐2 ๐2 = 1 The MGF is ๐ ๐ ) ๐ด๐ฟ(๐) = ( ๐−๐ ∞ ∫ ๐ฅ๐ −๐๐ฅ๐๐ฅ = ∫ ๐ฅ 2−1 ๐ −๐๐ฅ๐๐ฅ = 1 ∞ The probability density function of the general Gamma random variable ๐ is Where ๐ ๐๐๐ ๐ are the parameters. ๐(๐ฅ) = { Now we have to find ๐ Momentum generating Function of Gamma Distribution: ๐(๐ฅ) = { ๐ฅ๐ −๐๐ฅ , 0< ๐ฅ < ∞ . Determine the constant ๐ and 0, ๐๐กโ๐๐๐ค๐๐ ๐ ๐ =1 Then ๐(๐ฅ) = { ๐ฅ๐ −๐ฅ , 0<๐ฅ<∞ 0, ๐๐กโ๐๐๐ค๐๐ ๐ ∞ ∞ P (lifetime exceeds 2 hours) =๐(๐ > 2) = ∫2 ๐(๐ฅ)๐๐ฅ = ∫2 ๐ฅ๐ −๐ฅ ๐๐ฅ = 0.4060 Problem 2: Problem 3: The daily consumption of milk in a city, in excess of 20,000 liters, is approximately distributed as a Gamma variate with parameters ๐ = 2 ๐๐๐ ๐ = 1 10,000 . The city has a daily stock of 30,000 liters. What is the probability that the stock is insufficient on a particular day? In a certain city, the daily consumption of electric power (in millions of kilowatt-hours) can be 1 treated as a random variable having Gamma distribution with parameters ๐ = and ๐ = 3. If the 2 power plant of this city has a daily capacity of 12 million kilowatt hours, what is the probability that this power supply will be adequate on any day? Solution: If the random variable ๐ denotes the daily consumption of milk (in liters) in a city, then the random variable ๐ = ๐ − 20,000 has a Gamma distribution with probability density function ๐(๐ฅ) = ๐๐ ๐ฅ ๐−1๐ −๐๐ฅ ,๐ฅ ≥ 0 Γ(๐) = Γ(2) Let ๐ be the random variable denoting the daily consumption of electric power (in millions of kilowatt hours). 1 ๐2 ๐ฆ 2−1๐ −๐๐ฆ ,๐ฆ ≥ 0 ๐(๐ฆ) = Γ(2) 2 1 )๐ฆ 1 −( ( 10,000) ๐ฆ 2−1๐ 10,000 Solution: Also, given ๐ = and ๐ = 3. 2 Gamma distribution with probability distribution function is ๐(๐ฅ) = ,๐ฆ ≥ 0 ๐ฅ 1 3 − (2) ๐ฅ 3−1๐ 2 = ,๐ฅ ≥ 0 Γ(3) Since the daily stock of the city is 30,000 liters, the required probability that the stock is insufficient on a particular day is given by The daily capacity of the power plant is 12 million kilowatt hours. The power supply is more ∞ ๐(๐ > 30,000) = ๐(๐ > 10,000) = ∫ ∞ Taking ๐ง = ๐ฆ 10,000 =∫ 10,000 ∞ 2 1 ) ( 10,000 ๐ฆ − ๐ฆ 2−1๐ 10,000 Γ(2) 10,000 ∞ ๐(๐ฆ)๐๐ฆ than 12 million on any day. ∞ ∞( ๐(๐ > 12) = ∫ ๐(๐ฅ)๐๐ฅ = ∫ ๐๐ฆ = ∫ ๐ง๐ −๐ง ๐๐ง 12 1 ∫ ๐ง๐ −๐ง ๐๐ง = ๐ −1 + ๐ −1 = 2๐ −1 = 0.7357 1 ๐๐ ๐ฅ ๐−1๐ −๐๐ฅ Γ(๐) ∞( =∫ 12 Try yourself: Problem 4: 12 1 2 −๐ฅ2 ๐ฅ ๐ 8) ๐๐ฅ Γ(3) 1 2 −๐ฅ2 ๐ฅ ๐ 8) ๐๐ฅ = 0.0625 Γ(3) Γ(๐ผ) = Γ(3) = (3 − 1)! = 2! = 2 Consumer demand for milk in a certain locality per month is known to be a general Gamma Γ(๐ฝ) = Γ(2) = (2 − 1)! = 1! = 1 distribution random variable. If the average demand is ๐ liters and the most likely demand is ๐ Γ(๐ผ + ๐ฝ) = Γ(5) = (5 − 1)! = 4! = 24 liters (๐ < ๐), what is the variance of the demand? ๐(๐ฅ) = { 12๐ฅ 2(1 − ๐ฅ), 0, ๐๐๐ 0 < ๐ฅ < 1 ๐๐กโ๐๐๐ค๐๐ ๐ Thus, the desired probability as given by Beta Distribution: 1/2 ∫ 0 A continuous random variable X takes on values in the interval from 0 to 1. It has to follow the Beta distribution, if its probability density is given as Γ(๐ผ + ๐ฝ) ๐ผ−1 ๐ฅ (1 − ๐ฅ)๐ฝ−1, ๐๐๐ 0 < ๐ฅ < 1, ๐ผ > 0, ๐ฝ > 0 ๐(๐ฅ) = {Γ(๐ผ)Γ(๐ฝ) 0, ๐๐กโ๐๐๐ค๐๐ ๐ Note: ๐ผ๐ฝ ๐ผ ๐๐๐ ๐ 2 = (๐ผ + ๐ฝ)2 (๐ผ + ๐ฝ + 1) ๐ผ+๐ฝ If ๐ผ = 1 ๐๐๐ ๐ฝ = 1, we obtain as special case the uniform distribution. Problem: 5 16 Weibull distribution: The random variable X is said to follow Weibull distribution, if its probability distribution is given by ๐ฝ ๐ฝ−1 ๐ −๐ผ๐ฅ , ๐ฅ > 0 ๐(๐ฅ) = {๐ผ๐ฝ๐ฅ 0, ๐๐กโ๐๐๐ค๐๐ ๐ The mean and variance of this distribution are given by ๐= 12๐ฅ 2(1 − ๐ฅ)๐๐ฅ = Where ๐ผ > 0 ๐๐๐ ๐ฝ > 0 are two parameters of the Weibull distribution. Note: When ๐ฝ = 1, the Weibull distribution reduces to the exponential distribution with parameter ๐ผ. Mean and Variance of Weibull distribution: In a certain country, the proportion of highway sections requiring repairs in any given year is a random variable having the Beta distribution with ๐ผ = 3 ๐๐๐ ๐ฝ = 2 i. On average, what percentage of the highway sections require in any given year? ii. Find the probability that at most half of the highway sections will require repairs in any given year. Solution: i. ๐= ๐ผ ๐ผ+๐ฝ 3 = = 0.60 5 That is on the average 60% of the highway sections require repairs in any given year. ii. For ๐ผ = 3 ๐๐๐ ๐ฝ = 2 The probability density function of Weibull distribution is given by ๐ฝ ๐ฝ−1 ๐ −๐ผ๐ฅ , ๐ฅ>0 ๐(๐ฅ) = {๐ผ๐ฝ๐ฅ 0, ๐๐กโ๐๐๐ค๐๐ ๐ Where ๐ผ > 0 ๐๐๐ ๐ฝ > 0 are two parameters. Mean = ๐ธ(๐) = ๐ = ๐ผ 1 ๐ฝ − 1 Γ (1 + ) ๐ฝ 2 1 2 Suppose that the time to failure (in minutes) of certain electronic components subjected to Variance= ๐ 2 = ๐ผ −2/๐ฝ {Γ (1 + ) − [Γ (1 + )] } ๐ฝ ๐ฝ continuous vibrations may be looked upon as a random variable having the Weibull distribution with ๐ผ = i. ii. 1 5 ๐๐๐ ๐ฝ = 1 3 How long can such a component be expected to last? What is the probability that such a component will fail in less than 5 hours. Cumulative distribution function: ๐ญ(๐; ๐ถ, ๐ท) = { ๐ − ๐ ๐, −๐ถ๐๐ท , ๐≥๐ ๐< ๐ Solution: Mean is ๐ = ๐ผ i. The mean lifetime of these batteries ii. The probability that such battery will last more than 300 hours. Solution: i. ii. 1 ๐(๐ < 5 โ๐๐ข๐๐ ) = ๐(๐ < 300 ๐๐๐๐ข๐ก๐๐ ) ii. variable X having Weibull distribution with ๐ผ = 0.1 ๐๐๐ ๐ฝ = 0.5. Find i. 1 Γ (1 + ) ๐ฝ 1 −(1) 1 = ( ) 3 Γ (1 + ) = 53 3! = 750 ๐๐๐๐ข๐ก๐๐ 1 5 (3) Problem 1: Suppose that the lifetime of a certain kind of an emergency backup battery (in hours) is a random 1 ๐ฝ − 300 =∫ 0 ๐ฝ 300 ๐ผ๐ฝ๐ฅ ๐ฝ−1๐ −๐ผ๐ฅ ๐๐ฅ = ∫ 0 1 1 1 1 1 −( )(๐ฅ)3 ( ) ( ) ๐ฅ 3−1๐ 5 ๐๐ฅ = 0.7379 5 3 Or Mean is ๐ = ๐ผ 1 ๐ฝ − 1 Γ (1 + ) ๐ฝ 1 = (0.1)−0.5 Γ (1 + ∞ ๐ฝ ๐(๐ > 300) = ∫300 ๐ผ๐ฝ๐ฅ ๐ฝ−1๐ −๐ผ๐ฅ ๐๐ฅ 1 )= 0.5 2 1 2 ( 10) ∞ = 200 โ๐๐ข๐๐ 0.5 = ∫ (0.1)(0.5)๐ฅ −0.5๐ −0.1(๐ฅ) ๐๐ฅ 300 = 0.1769 1 1 −๐ผ๐ฅ๐ฝ , ๐น (300; , ) = {1 − ๐ 5 3 0, 1 1 (300) 3 = 1 − ๐ −5 ๐ฅ≥0 ๐ฅ<0 = 0.7379 The failure rate of the Weibull distribution: ๏ง The Weibull distribution helps to determine the failure rate (or hazard rate) in order to get a sense of deterioration of the component. Problem 2: ๏ง Consider the reliability of a component or product as the probability that it will function property for at least a specified time to under specified experimental conditions. ๏ง Then the failure rate at time ‘t’ for the Weibull distribution is given by ๐(๐) = ๐ถ๐ท๐๐ท−๐ , ๐ > ๐ Interpretation of the failure rate; 1. If ๐ฝ = 1, the failure rate=๐ผ, a constant. This is the special case of the exponential distribution in which lack of memoryless property. 2. If ๐ฝ > 1, ๐(๐ก) is an increasing function of time ‘t’, which indicates that the component wears over time. 3. If ๐ฝ < 1 , ๐(๐ก) is decreasing function of time ‘t’ and hence the component strengthens or hardness over time. Problem: The length of life X, in hours of an item in a machine shop has a Weibull distribution with ๐ผ = 0.01 ๐๐๐ ๐ฝ = 2 i. What is the probability that it fails before eight hours of usage? ii. Determine the failure rates. ๐ญ(๐; ๐ถ, ๐ท) = { ๐ − ๐ ๐, −๐ถ๐๐ท , ๐≥๐ ๐< ๐ Solution: i. ii. 2 ๐(๐ < 8) = ๐น(8) = 1 − ๐ −(0.01)8 = 1 − 0.257 = 0.473 Here ๐ฝ = 2, and hence it wears over time and the failure rate is given by If ๐ฝ = 3 4 ๐(๐ก) = 0.02 ๐ก ๐๐๐ ๐ผ = 2, then Hence the component gets stronger over time. ๐(๐ก) = 1.5 ๐ก 1/4 Module-6 Hypothesis Testing-I Introduction: ๏ง ๏ง ๏ง ๏ง ๏ง Population are often described by the distribution of their values. Sample is a part of population. Statistical measures (such as mean and variance) calculated on the basis of population are called parameters. Corresponding measures computed on the basis of sample observations are called statistics Sampling distribution: The distribution of a statistics calculated on the basis of a random sample is basic to all of statistical inference Or The probability distribution of the statistics that would be obtained, if the number of samples, each of same size, were infinitely large is called the sampling distribution of the statistics. Notation: Population Parameters Population mean (๐) Population standard deviation (๐) Population size (๐) Population proportion (๐) Standard error: Sample Statistics Sample mean (๐ฬ ) Sample standard deviation (๐) Sample size (๐) Sample proportion (๐) The standard deviation of the sampling distribution of a statistic is called the standard error of the statistics. It has most important in tests of hypothesis. 1. Let ๐1 , ๐2, ๐3, … , ๐๐ be a sample of values from a population, then the sample mean is defined by ๐ + ๐2 + ๐3 + โฏ + ๐๐ ∑๐๐=1 ๐๐ ฬ ๐ = 1 = ๐ ๐ and sample variance is defined by ∑๐๐=1(๐๐ − ฬ ๐ )2 ๐−1 ฬ Since the values of the sample mean ๐ is determined by the values of the random variables in the sample, if it follows that ฬ ๐ is also a random variable ๐1 + ๐2 + ๐3 + โฏ + ๐๐ ๐ ฬ ๐ = ๐ธ ( ) ๐ 1 = (๐ธ(๐1) + ๐ธ(๐2 ) + โฏ + ๐ธ(๐๐ )) ๐ ๐ 2 = =๐ ๐ +๐ +๐ +โฏ+๐๐ Var (๐ฬ ) = ๐ ฬ ๐ 2 = ๐๐๐ ( 1 2 3 ) = ๐ 1 (๐๐๐(๐1 ) + ๐๐๐(๐2 )+. . . +๐๐๐(๐๐ )) ๐2 = ๐๐ 2 ๐2 ๐2 = ๐ 2. If a random sample of size ๐ is taken from a population having the mean ๐ and the variance ๐ 2, then ๐ฬ is a random variable whose distribution has the mean ๐ and variance ๐2 for samples from infinite population ๐ ๐−1 for samples from a finite population of size ๐ ๐ ๐2 ๐−๐ Standard error of the mean ๐ ฬ ๐ = ๐ ฬ ๐ = ๐ √๐ ๐ √๐ (infinite population) √ ๐−๐ ๐−1 (finite population) Sampling distribution of mean (๐ ๐๐๐๐๐): If ฬ ๐ is the mean of a random sample of size ๐ taken from a population having the mean ๐ and the finite variance ๐ 2, then ๐= ฬ ๐ − ๐ ๐ √๐ is a random variable whose distribution function approaches that of the standard normal distribution as ๐ → ∞. Sampling distribution of mean (๐ ๐๐๐๐๐๐๐): If ฬ ๐ is the mean of a random sample of size ๐ taken from a normal population having the mean ๐ and the finite variance ๐ 2, and ๐ 2 = ∑๐ ๐)2 ๐=1(๐๐ − ฬ ๐−1 then ๐ก= ฬ ๐ − ๐ ๐ √๐ is a random variable having t-distribution with parameter ๐ = ๐ − 1. Sampling distribution of the variance: If ๐ 2 is the variance of a random sample of size ๐ taken from a normal population having the variance ๐ 2, then ๐2 (๐ − 1)๐ 2 = ๐2 ๐๐ = ∑๐๐=๐(๐ฟ๐ − ฬ ๐ฟ)๐ ๐๐ is a random variable having ๐๐ − distribution with the parameter ๐ = ๐ − 1. If ๐ 1 2 ๐๐๐ ๐ 22 are the variances of independent random samples of size ๐1 ๐๐๐ ๐2 respectively, taken from two normal populations having the same variance, then ๐น = ๐ 1 2 ๐ 2 2 is a random variable having the F-distribution with the parameter ๐1 = ๐1 − 1 ๐๐๐ ๐2 = ๐2 − 1. Hypothesis testing: Hypothesis testing is a method for testing a claim/hypothesis about a parameter in a population using data measured in a sample. Statistical hypothesis: 1. It is a statement or claim about one or more population parameters. 2. Hypothesis testing is formulated in terms of two hypothesis: ๐ป0: The null hypothesis (this is the negation of the claim) ๐ป1: The alternative hypothesis (this is the claim we wish to establish) 3. In ๐ป0, a statement involving equality (=, ≥, ≤) In ๐ป1, a statement involving equality (≠, >, <) The hypothesis we want to test, if ๐ป1 is “likely” two So, there are two possible outcomes ๏ง ๏ง Reject ๐ป0 and accept ๐ป1because of sufficient evidence in the sample in favor of ๐ป1 Do not reject ๐ป0because of insufficient evidence to support ๐ป1. Critical region: The region of rejection or critical region as the region beyond a critical value in a hypothesis test. When the value of a test statistic is in the rejection region, we decide to reject the ๐ป0. Otherwise, will accept it. Level of significance (LOS): The probability that a random value (๐ผ)of the statistic lies in the critical region is called level of significance and is usually expressed as a percentage. Or The total area of the critical region expressed as ๐ผ % is the loss of significance. Types of test: Suppose we test for population mean, then Null hypothesis ๐ป0: ๐ = ๐0 Alternative hypothesis ๐ป1: ๐ ≠ ๐0 ๐๐ ๐ > ๐0 ๐๐ ๐ < ๐0 If ๐ ≠ ๐0, then the test is called two-tailed test. If ๐ > ๐0, then the test is called right-tailed test (One-tailed) If ๐ < ๐0, then the test is called left-tailed test (One-tailed) A critical value is a cutoff value that of the boundaries beyond which less than 5% of sample means can be obtained, if the Null hypothesis is true. Same means obtained beyond a critical value will result in a decision to reject the null hypothesis. Level of significance (๐ถ) 5% (0.05) 1% (0.01) 10% (0.1) Types of test One-tailed +1.645 or - 1.645 +2.33 or - 2.33 +3.09 or - 3.09 Two-tailed ± 1.96 ± 2.58 ± 3.30 Types of error and their probabilities: Reject ๐ป0 Accept ๐ป0 ๐ผ -Level of significanceOr P (type-I error) = ๐ถ ๐ป0 is true Type-I error Correct decision ๐ป0 is false Correct decision Type-II error probability of making type-I error Similarly, P (type-II error) = ๐ท Steps involved in hypothesis testing: 1. 2. 3. 4. 5. 6. Formulate Null and alternate hypothesis Identify the level of significance Set the criteria for a decision Compute test statistics Critical or rejection region Draw a conclusion or make decision If ๐ ≥ ๐๐ is a large sample If ๐ < ๐๐ is a small sample Hypothesis concerning one mean or test of single mean condition: ๏ง ๏ง Either a population is a normally distributed sample size should be large i.e., ๐ ≥ 30 Population standard deviation ๐ should be known. If it is not known, then we can use a sample standard deviation ′๐ ′, instead of provided ๐ ≥ 30 Test of single mean condition: ๏ง ๐ป0: ๐ = ๐0 Test statistic: Statistic for test concerning mean (๐ known) is ฬ ๐ − ๐0 ๐= ๐ √๐ Which follows standard normal distribution ๏ง Critical regions for testing ๐ = ๐0 (standard normal distribution and ๐ be known) Alternative hypothesis ๐ < ๐0 ๐ > ๐0 ๐ ≠ ๐0 ๐ป0 Reject Null hypothesis ๐ < −๐๐ผ ๐ > ๐๐ผ ๐ < − ๐๐ผ/2 or ๐ > ๐๐ผ/2 Example 1: Suppose, for instance, we want to establish that the thermal conductivity of a certain kind of cement brick differs from 0.340, the value claimed. We will test on the basis of ๐ = 35 determinations and at the 0.05 level of significance. From information gathered in similar studies, we can except that the variability of such determinations is given by ๐ = 0.01 and mean=0.343. Solution: ๐ = 35, ฬ ๐ = 0.340, ๐ = 0.01 1. Null hypothesis: Alternative hypothesis: ๐ป0: ๐ = 0.340 ๐ป1: ๐ ≠ 0.340 2. The level of significance is ๐ผ = 0.05 3. Test Statistic: ๐= ๐= 4. Critical region: ฬ ๐ − ๐ ๐ √๐ 0.340 − 0.343 = −1.77 0.01 √35 Since it is a two-tailed test, the critical value is ๐๐ผ/2 = 1.96 5. Decision: Since ๐ = −1.77 falls on the interval from -1.96 to 1.96, the null hypothesis can not be rejected. i.e., null hypothesis is accepted. Example 2: The mean lifetime of a sample of 100 tube lights produced by a company is found to be 1580 hours with standard deviation of 90 hours. Test the hypothesis at 1% loss of significance, that the mean lifetime of the tubes produced by the company is 1600 hours. Solution: ๐ = 100, ฬ ๐ = 1580, ๐ = 90 1. ๐ป0: ๐ = 1600 against ๐ป1: ๐ ≠ 1600 (two tailed test) 2. The level of significance is ๐ผ = 0.01 3. Test Statistic: Since ๐ ≥ 30, ๐ follows standard normal distribution ๐= = ฬ ๐ − ๐ ๐ √๐ 1580 − 1600 = −2.22 90 √100 ๐ = −2.22 4. Critical region: Since it is a two-tailed test, the critical value is ๐๐ผ/2 = 2.58 5. Decision: Since ๐ = −2.22 falls on the interval from -2.58 to 2.58, the null hypothesis cannot be rejected. So, we accept the null hypothesis. We conclude that the mean lifetime of the tubes produced by the company is 1600 hours. Example 3: In a random sample of 60 workers, the average time taken by them to get to work is 33.8 minutes with a standard deviation of 6.1 minutes. Can we reject the null hypothesis ๐ = 32.6 minutes in favor of alternative null hypothesis ๐ > 32.6 at ๐ผ = 0.025 level of significance? Solution: ๐ = 160, ฬ ๐ = 33.8, ๐ = 6.1 1. ๐ป0: ๐ = 32.6 against ๐ป1: ๐ > 32.6 (one-tailed test) 2. The level of significance is ๐ผ = 0.025 3. Test Statistic: Since ๐ ≥ 30, ๐ follows standard normal distribution ๐= ฬ ๐ − ๐ ๐ √๐ = 4. Critical region: 33.8 − 32.6 = 1.52 6.1 √60 Since it is a one-tailed test, the critical value is ๐๐ผ/2 = 1.645 5. Decision: Since ๐ = 1.52 falls on the interval from -1.645 to 1.645, so the null hypothesis cannot be rejected. So, we accept the null hypothesis. Example 4: A sample of 400 items is taken from a population whose standard deviation is 10. The mean of the sample is 40. Test whether the sample has come from a population with mean 38. Also calculate 95% confidence interval for the population. Solution: ๐ = 400, ฬ ๐ = 40, 1. ๐ป0: ๐ = 32.6 against ๐ป1: ๐ ≠ 32.6 (two- tailed test) 2. The level of significance is ๐ผ = 0.05 3. Test Statistic: ๐ = 38, ๐ = 10 Since ๐ ≥ 30, ๐ follows standard normal distribution ๐= = 4. Critical region: ฬ ๐ − ๐ ๐ √๐ 40 − 38 =4 10 √400 Since it is a two-tailed test, the critical value is ๐๐ผ/2 = 1.96 5. Decision: Since ๐ = 4 is out of the interval from -1.96 to 1.96, so the null hypothesis is rejected. That is, the sample is not from the population whose mean is 38. Next, we have to find the 95% confidence interval ( ฬ ๐ − 1.96 = (40 − 1.96. ๐ √๐ 10 ๐ , ฬ ๐ + 1.96 √400 √๐ , 40 + 1.96. ) 10 √400 = (40 − 0.98 , 40 + 0.98 ) ) = (39.02, 40.98 ) Example 5: An insurance agent has claimed that the average age of policy holders who issue through him the average for all agents which is 30.5 years. A random sample of 100 policy holders who had issued through him gave the following age distribution. Age No. of persons 16-20 12 21-25 22 26-30 20 31-35 30 36-40 16 Calculate the arithmetic mean and standard deviation of this distribution and use the values to test his claim at 5% level of significance. Solution: Take ๐ด = 28, ๐๐ = ๐๐ − ๐ด, โ = 5, ๐ = 100 ฬ ๐ = ๐ด + = 28 + The standard deviation is โ ∑ ๐๐ ๐๐ ๐ 5(16) = 28.8 100 ฬ ๐ = 28.8 2 ∑ ๐๐2 ∑ ๐๐ ๐ =√ − ( ) ๐ ๐ 164 16 2 √ = 5( − ( ) ) = 6.35 100 100 ๐ = 6.35 1. Null hypothesis ๐ป0: The sample is drawn from a population with mean ๐ i.e., ฬ ๐ and ๐ do not differ significantly where ๐ = 30.5 years. Alternative hypothesis ๐ป1: ๐ < 32.6 (one- tailed test i.e., left tail test) ๐ = 100, ฬ ๐ = 28.8, ๐ = 30.5, ๐ = 6.35 2. The level of significance is ๐ผ = 5% = 0.05 3. Test Statistic: Since ๐ ≥ 30, ๐ follows standard normal distribution ๐= = 4. Critical region: ฬ ๐ − ๐ ๐ √๐ 28.8 − 30.5 = −2.677 ≈ − 2.68 6.35 √100 Since it is a one-tailed test, the critical value is ๐๐ผ/2 = 1.645 5. Decision: Since ๐ = −2.645 is out of the interval from -1.645 to 1.645, so the null hypothesis is rejected at 5% level of significance. Try yourself: 6. The mean and standard deviation of a population are 11795 and 41054, respectively. If ๐ = 50, find 95% confidence interval for the mean. 7. It is claimed that a random sample of 49 tyres has a mean life of 15200 km. this sample was drawn from a population whose mean is 15150 kms and a standard deviation of 1200 km. test the significance at 0.05 level. 8. An ambulance service claims that it takes on average less than 10 minutes to reach its destination in emergency calls. A sample of 36 calls has a mean of 11 minutes and the variance of 16 minutes. Test the significance of 0.05 level. Example 9: Suppose that a consumer agency wishes to establish that that the population mean is less than 71 pounds, the target amount established for this product. There are ๐ = 80 observations and a computer calculation give ฬ ๐ฅ = 68.45 and ๐ = 9.583.what can it conclude if the probability of a type I error is to be at most 0.01? Solution: ๐ป0: ๐ ≥ 71 pounds ๐ป1: ๐ < 71 pounds The level of significance is ๐ผ ≤ 0.01 Criterion: Since the probability of a type I error is greatest when ๐ = 71 pounds we proceed as if we were testing the ๐ป0: ๐ = 71 pounds against ๐ป1: ๐ < 71 pounds at the 0.01 level of significance. Thus ๐ป0 must be rejected, if ๐ < − ๐๐ผ i.e., ๐ < − 2.33 where ๐= = Decision: ฬ ๐ − ๐ ๐ √๐ 68.45 − 71 = −2.38 9.583 √80 ๐ = −2.38 Since ๐ = −2.38 is less than – 2.33, ๐ป0 must be rejected at level of significance 0.01 or we can say, the suspicion that ๐ < 71 pounds confirmed. Two independent large samples( ๐๐ ≥ ๐๐, ๐๐ ≥ ๐๐): 1. Let ๐ฟ๐ , ๐ฟ๐ , ๐ฟ๐ , . . . , ๐ฟ๐ is a random sample of size ๐1 from population 1 which has mean=๐1 and variance=๐12 . 2. Let ๐๐, ๐๐ , ๐๐ , . . . , ๐๐ is a random sample of size ๐2 from population 2 which has mean=๐2 and variance=๐22. 3. Two samples ๐ฟ๐ , ๐ฟ๐ , ๐ฟ๐ , . . . , ๐ฟ๐ and ๐๐, ๐๐ , ๐๐ , . . . , ๐๐ are independent ๐ฌ( ฬ ๐ ) = ๐1 ๐๐๐ ๐ฌ( ฬ ๐ ) = ๐2 ๐22 ๐1 2 ๐ฝ๐๐( ฬ ๐ ) = 2 ๐๐๐ ๐ฝ๐๐( ฬ ๐ ) = 2 ๐2 ๐1 ๐ฌ( ฬ ๐ − ฬ ๐ ) = ๐๐ − ๐๐ = ๐น (say) Two-sample Z statistics is ๐ฝ๐๐( ฬ ๐ − ฬ ๐ ) = ๐= ๐1 2 ๐22 + ๐1 2 ๐2 2 ฬ ๐ − ฬ ๐ − ๐ฟ √ ๐12 ๐2 2 + ๐1 ๐2 When the sample sizes ๐1 ๐๐๐ ๐2 , then the statistic for large samples inferences concerning difference between two means will be ๐= ฬ ๐ − ฬ ๐ − ๐ฟ √ ๐12 ๐2 2 + ๐2 ๐1 Hypothesis test concerning two mean: Formulation: ๏ง ๏ง If we consider ๐ป0: ๐1 − ๐2 = ๐ฟ0 tests of their ๐ป0 against each of the ๐ป1: ๐1 − ๐2 < ๐ฟ0 , ๐1 − ๐2 > ๐ฟ0 , ๐1 − ๐2 ≠ ๐ฟ0 . The test itself will depend on the distance measured in estimated standard deviation units, from the difference in sample means ฬ ๐ − ฬ ๐ to the hypothesized value ๐ฟ0 . Test statistic for large samples concerning a difference between two means: When ๐1 ≥ 30, ๐2 ≥ 30, to test ๐ป0 = ๐1 − ๐2 = ๐ฟ0 , we will use the Z-statistic ๐= ฬ ๐ − ฬ ๐ − ๐ฟ0 √ ๐ 12 ๐ 2 2 + ๐2 ๐1 Critical regions for testing ๐1 − ๐2 = ๐ฟ0 (normal population and ๐1 , ๐2 are known or large samples ๐1 ≥ 30, ๐2 ≥ 30) Alternative hypothesis ๐ฏ๐ ๐1 − ๐2 < ๐ฟ0 ๐1 − ๐2 > ๐ฟ0 ๐1 − ๐2 ≠ ๐ฟ0 ๐ฏ๐ Reject Null hypothesis ๐ < −๐๐ผ ๐ > ๐๐ผ ๐ < − ๐๐ผ/2 or ๐ > ๐๐ผ/2 Note: Somewhere ๐ป0 can be ๐1 = ๐2, as ๐ฟ0 can be any constant. Problem: To test the claim that the resistance of electric wire can be reduced by more than 0.050 Ohm by alloying, 32 values obtained for standard wire yielded ฬ ๐ = 0.136 Ohm and ๐ 1 = 0.004 Ohm and 32 values obtained for alloyed wire yielded ฬ ๐ = 0.083 Ohm and ๐ 2 = 0.005 Ohm. At the 0.05 level of significance, does this support the claim? Solution: ๐ป0: ๐1 − ๐2 = 0.050 The level of significance: ๐ผ = 0.05 Test Statistic: ๐ป1 : ๐1 − ๐2 > 0.050 ๐= = Decision: ฬ ๐ − ฬ ๐ − ๐ฟ0 √ ๐ 12 ๐ 2 2 + ๐2 ๐1 0.136 − 0.083 − 0.050 2 2 √(0.004) + (0.005) 32 32 = 2.65 Since ๐ = 2.65 exceeds 1.96, so ๐ป0 must be rejected. Large sample test of the ๐ฏ๐ at the equality of two means: Problem 1: The means of two large samples of sizes 1000 and 2000 members are 67.5 inches and 68 inches respectively. Can be the samples regarded as drawn from the same population of standard deviation 2.5 inches. Solution: Given that ๐1 = 1000, ๐2 = 2000, ฬ ๐ = 67.5, ฬ ๐ = 68 Null hypothesis: the samples have drawn from the sample population of standard deviation ๐ = 2.5 inches. i.e., ๐ป0: ๐1 = ๐2. Alternative hypothesis: ๐ป1 : ๐1 ≠ ๐2. The level of significance: ๐ผ = 5% Test Statistic: ๐= = ฬ ๐ − ฬ ๐ − ๐ฟ0 √ ๐ 12 ๐ 2 2 + ๐1 ๐2 67.5 − 68 − 0 2 2 √(2.5) + (2.5) 1000 2000 = − 5.16 ๐ = − 5.16 Decision: Since ๐ = − 5.16 exceeds 1.96. Therefore, the null hypothesis is rejected at 5% level of significance. i.e., the samples are not drawn from the same population of standard deviation 2.5 inches. Problem 2: In a survey of buying habits, 400 women shoppers are chosen at random in super market A located in a certain section of the city. Their average weekly food expenditure is Rs. 250 with a standard deviation of Rs. 40. For 400 women shoppers chosen at random in super market B in another section of the city, the average weekly food expenditure is Rs. 220 with a standard deviation of Rs. 55. Test a 10% level of significance whether the average weekly food expenditure of the two populations of the shoppers are equal. Solution: ๐1 = 400, ๐2 = 400, ฬ ๐ = 250, ฬ ๐ = 220, ๐ 1 = 40, ๐ 2 = 55 Null hypothesis: Assume that the average weekly food expenditure of the two populations of the shoppers are equal i.e., ๐ป0: ๐1 = ๐2. Alternative hypothesis: ๐ป1 : ๐1 ≠ ๐2. The level of significance: ๐ผ = 10% Test Statistic: ๐= = Decision: Since ๐ = 8.82 exceeds 3.30. ฬ ๐ − ฬ ๐ − ๐ฟ0 √ ๐ 12 ๐ 2 2 + ๐2 ๐1 250 − 220 − 0 2 2 √(40) + (55) 400 400 = 8.82 ๐ = 8.82 Therefore, the null hypothesis is rejected at 10% level of significance. i.e., the average weekly food expenditure of the two populations are not equal. Problem 3: Samples of students were drawn from two universities and from their weights in kilograms, mean and standard deviations are calculated and shown in below. Make a large sample test to test the level of significance between the means Mean 55 57 University A University B Standard deviation 10 15 Size of the sample 400 100 Inferences concerning Proportions: Proportion: A proportion refers to the fraction of the total population possesses a certain attribute. Example: Suppose we have a sample of four pets; a bird, a fish, a dog and a cat. If we ask what proportion has four legs, then only two pets (the dog and the cat) have four legs, therefore the proportion of 2 pets with four legs is ‘ ’or 0.5. 4 A proportion, denoted by ′๐′ is a parameter that describes a percentage value associated with a population. Example: A survey showed 83% of women in a village are illiterate, the value 0.83 is a population proportion. Finding of sample proportion: ๐~๐ต(๐, ๐)with mean ๐ธ(๐ฅ) = ๐๐, variance ๐(๐) = ๐๐๐, where ๐ = 1 − ๐ When ๐ is very large, then ๐~๐(๐๐, ๐๐๐ ), i.e., a Normal distribution with mean ‘๐๐’ and standard deviation is √๐๐๐. To form a sample proportion, divide the random variable ๐ for the number of successes by the number of trials (๐). i.e., ๐ = Now, ๐ ๐ is a sample proportion in a random sample of size ๐. ๐ ๐๐ ๐๐๐ ~๐ { , √ 2 } ๐ ๐ ๐ ๐๐ ๐~๐ {๐, √ } ๐ Therefore, the test statistics ′๐′ is given by ๐= ๐−๐ท √๐ท๐ธ ๐ Test for single Proportion (Large sample): Condition: ๐๐ ≥ 5 ๐๐๐ ๐(1 − ๐) ≥ 5. Null hypothesis: ๐ป0: ๐ = ๐0 Test statistics: ๐ = = ๐ฟ−๐๐ท๐ √๐ท๐ (๐−๐ท๐ ) ๐ − ๐๐ท๐ √๐ท๐ (๐ − ๐ท๐ ) ๐ Which is a random variable having approximately the standard normal distribution. Critical region for testing ๐ท = ๐ท๐ (Large sample): Alternative hypothesis ๐ฏ๐ ๐ < ๐0 ๐ > ๐0 p≠ ๐0 ๐ฏ๐ Reject Null hypothesis ๐ < −๐๐ผ ๐ > ๐๐ผ ๐ < − ๐๐ผ/2 or ๐ > ๐๐ผ/2 Example 1: In a sample of 1000 people Karnataka 540 are rice eaters and the rest are wheat eaters. Can we assume that the both rice and wheat are equally popular in this state at 1% level of significance? Solution: ๐ = 540, ๐ = 1000 ๐= 540 ๐ = = 0.54 ๐ 1000 ๐= 1 = 0.5 2 ๐ = 1 − ๐ = 0.5 Null hypothesis: ๐ป0: Both rice and wheat are equally popular in the state. Alternative hypothesis: ๐ป1: ๐ ≠ 0.5 (two- tailed test) Loss of significance: ๐ผ = 0.01 Test Statistics: ๐= ๐−๐ √๐๐ ๐ = 0.54 − 0.5 √0.5 × 0.5 1000 = 2.532 ๐ = 2.532 The tabulated value of ๐ at 1% level of significance for two tailed test is 2.58. Since calculated ๐ = 2.532 < 2.58. So, we accept null hypothesis ๐ป0 at 1% level of significance. i.e., both rice and wheat are equally likely popular in the state. Example 2: 40 people were attacked by a disease and only 36 survived. Will you reject the hypothesis that the survival rate, if attacked by this disease is 85% in favor of the hypothesis that it is more at 5% level of significance. Solution: Let ๐ denotes the number of people attacked by disease and survived Here ๐ = 36, ๐ = 40, ๐ = 0.85, ๐ = 0.15, ๐ = 0.9 Sample proportion is ๐ = ๐ ๐ = 36 40 Null hypothesis: ๐ป0: ๐ = 0.85 = 0.9 Alternative hypothesis: ๐ป1 : ๐ > 0.85 (Right tailed test) Loss of significance: ๐ผ = 0.05 Test Statistics: consider the conditions ๐๐ = 40 × 0.85 = 34 > 5 ๐(1 − ๐) = 40 × 0.15 = 6 > 5 ๐= Critical region: ๐ > ๐๐ถ ๐−๐ท √๐ท๐ธ ๐ = ๐. ๐ − ๐. ๐๐ √๐. ๐๐ × ๐. ๐๐ ๐๐ = ๐. ๐๐๐๐ Since calculation of ๐ = 0.8856 < 1.645 i.e., −1.645 < 0.8856 < 1.645 Hence, we fail to reject ๐ป0. i.e., accept ๐ป0. i.e., there is no statistical evidence to prove that more than 85% of the people are attacked by a disease and survived. Example 3: Experience had shown that 20% of a manufactured product is of the top quantity. In one day’s, production of 400 articles only 50 are of top quality. Test the hypothesis at 0.05 level. Example 4: In a random sample of 125 cool drinkers, 68 said they prefer thumps up to Pepsi. Test the hypothesis ๐ = 0.5 against the alternative hypothesis ๐ > 0.5. Test for the difference between two sample Proportions: Let ๐1 ๐๐๐ ๐2 be the proportions of successes in two large samples of size ๐1 ๐๐๐ ๐2respectively, drawn from the sample population or from two populations with the same proportion ๐1 = ๐2 = ๐. ๐๐ ๐๐ ๐1 ~๐ {๐, √ } ๐๐๐ ๐2~๐ {๐, √ } ๐1 ๐2 Then, ๐1 − ๐2 ~๐ {0, √๐๐ ( 1 ๐1 + 1 ๐2 )} With mean ๐ธ(๐1 − ๐2 ) = ๐ธ(๐1) − ๐ธ(๐2 ) = ๐ − ๐ = 0 ๐(๐1 − ๐2 ) = ๐(๐1) + ๐(๐2 ) = ๐๐ ( 1 ๐1 Test statistics: + ๐= 1 ๐2 ) (since the two samples are independent) ๐1 − ๐2 1 1 √๐๐ (๐ + ๐ ) 1 2 where population proportion mean ๐ is known. If, ๐ is not known, an unbiased estimate of ๐ based on the both samples, given by ๐= ๐1 ๐1 +๐2 ๐2 ๐1 +๐2 is used in the place of ๐. Critical region for two sample proportion (Large sample): Alternative hypothesis ๐ฏ๐ ๐1 − ๐2 < ๐0 ๐1 − ๐2 > ๐0 ๐1 − ๐2 ≠ ๐0 ๐ฏ๐ Reject Null hypothesis ๐ < −๐๐ผ ๐ > ๐๐ผ ๐ < − ๐๐ผ/2 or ๐ > ๐๐ผ/2 Condition: ๐1 ๐1 ≥ 5, ๐1 ๐1 ≥ 5, ๐2๐2 ≥ 5, ๐2๐2 ≥ 5. Problem 1: In a random sample of 100 men taken from village A, 60 were found to be consuming alcohol. In another sample of 200 men taken from village B, 100 were found to be consuming alcohol. Do the two villages differ significantly in respect to the proportion of men who consume alcohol? Solution: Let ๐ฅ1 = 60, ๐1 = 100, ๐ฅ2 = 100, ๐2 = 200 Same proportion ๐1 = ๐ฅ1 ๐1 = 60 100 = 0.6, ๐2 = Null hypothesis: ๐ป0: ๐1 − ๐2 = 0 ๐ฅ2 ๐2 = 100 200 = 0.5 Alternative hypothesis: ๐ป1 : ๐1 − ๐2 ≠ 0 Level of significance: ๐ผ = 0.05 Test statistic: under the following conditions ๐1 ๐1 = 100 × 0.6 = 60 > 5, ๐1 ๐1 = 40 > 5, ๐2๐2 = 100 > 5, ๐2 ๐2 = 100 > 5. ๐= ๐= ๐1 ๐1 + ๐2 ๐2 100 × 0.6 + 200 × 0.5 = = 0.533 ๐1 + ๐2 100 + 200 ๐1 − ๐2 1 1 √๐๐ (๐ + ๐ ) 1 2 = 0.6 − 0.5 1 1 ) √0.533 × 0.467 × ( + 100 200 Since −1.96 < ๐ = 1.636 < 1.96 = 1.6366 ๐ = 1.6366 We will fail to reject, i.e., Null hypothesis ๐ป0 is accepted. Problem 2: A manufacturer of electronic equipment subjects’ samples of two completing brands of transistors to an accelerated performance test. If 45 of 180 transistors of the first kind and 34 of 120 transistors of the second kind fail the test, what can conclude at the level of significance 0.05 about the difference between the corresponding sample proportions? Solution: Let ๐ฅ1 = 45, ๐1 = 180, ๐ฅ2 = 34, ๐2 = 120 Same proportion ๐1 = ๐ฅ1 ๐1 ๐= = 45 180 = 0.25, ๐2 = ๐ฅ2 ๐2 = 134 120 = 0.283 ๐1 ๐1 + ๐2 ๐2 ๐ฅ1 + ๐ฅ2 45 + 34 = = = 0.263 ๐1 + ๐2 180 + 120 ๐1 + ๐2 ๐ = 1 − ๐ = 1 − 0.263 = 0.737 Null hypothesis: ๐ป0: ๐1 − ๐2 = 0 Alternative hypothesis: ๐ป1 : ๐1 − ๐2 ≠ 0 Level of significance: ๐ผ = 0.05 Test statistic: under the following conditions ๐1 ๐1 = 180 × 0.25 = 45 > 5, ๐1 ๐1 = 180 × 0.75 = 135 > 5, ๐2 ๐2 = 120 × 0.283 = 40 > 5, ๐2 ๐2 = 120 × 0.737 = 86 > 5. ๐= ๐1 − ๐2 1 1 √๐๐ (๐ + ๐ ) 2 1 = Since −1.96 < ๐ = −0.647 < 1.96 0.25 − 0.283 1 1 √0.263 × 0.737 × ( ) + 180 120 = −0.647 ๐ = −0.647 We will fail to reject, i.e., Null hypothesis ๐ป0 is accepted. Example 3: Random samples of 400 men and 600 women were asked whether they would like to have flyover near their residence. 200 men and 325 women were in favor of the proposal. Test the hypothesis that proportions of men and women in favor of the proposal are same at 5% level. Solution: Let ๐ฅ1 = 200, ๐1 = 400, ๐ฅ2 = 325, ๐2 = 600 Same proportion ๐1 = ๐ฅ1 ๐1 ๐= = 200 400 = 0.5, ๐2 = ๐ฅ2 ๐2 = 325 600 = 0.541 200 + 325 ๐1 ๐1 + ๐2 ๐2 ๐ฅ1 + ๐ฅ2 = = = 0.525 ๐1 + ๐2 ๐1 + ๐2 400 + 600 ๐ = 1 − ๐ = 1 − 0.545 = 0.475 Null hypothesis: ๐ป0: ๐1 − ๐2 = 0 Alternative hypothesis: ๐ป1 : ๐1 − ๐2 ≠ 0 Level of significance: ๐ผ = 0.05 Test statistic: under the following conditions ๐= ๐1 − ๐2 1 1 √๐๐ (๐ + ๐ ) 1 2 = 0.5 − 0.541 1 1 √0.525 × 0.475 × ( ) + 400 600 = −1.28 Since −1.96 < ๐ = −1.28 < 1.96 ๐ = −1.28 We will fail to reject, i.e., Null hypothesis ๐ป0 is accepted. Try yourself: Example 4: A cigarette manufacturing firm claims that its brand A line of cigarette outsells its brand B by 8%. If it is found that 42 out of a sample of 200 smokers prefer brand A and 18 out of another sample of 8% difference is valid claim. Module 7 Hypothesis Testing-II Small Sample test: ๏ง ๏ง If the population is normally distributed and ๐ is known or if ๐ is unknown and ๐ ≥ 30 then we can apply Z-test (standard Normal distribution). If the population is normally distributed, ๐ is unknown and ๐ < 30, then we apply t-test (student’s t distribution). Student’s t-distribution: The probability density function of t-distribution is ๐(๐ก) = ๐+1 ) 1 2 ๐+1 ๐ √๐๐ Γ(2) ๐ก2 2 (1+ ) ๐ Γ( where ′๐′ degrees of freedom (the number of independent values or quantities which can be assigned to statistical distribution). Statistic for small sample test concerning one mean: Null hypothesis: ๐ป0: ๐ = ๐0 Test Statistic: ๐ก= ๐ฬ − ๐0 ๐ √๐ follows t-distribution with ๐ − 1 degrees of freedom. Here ๐ 2 = ∑(๐๐ −๐ฬ )2 ๐−1 is an unbiased estimator of population standard deviation ๐ 2. The relation between S and s (sample standard deviation) is ๐ ) ๐ = ๐ (√ ๐−1 ๐ Standard error is . Critical region: √๐ Level ๐ผ rejection region for testing ๐ = ๐0 (normal population and ๐ unknown) one sample t-test. Alternative hypothesis ๐ป1 ๐ < ๐0 ๐ > ๐0 ๐ ≠ ๐0 ๐ป0 Reject Null hypothesis ๐ก < −๐ก๐ผ ๐ก > ๐ก๐ผ ๐ก < − ๐ก๐ผ/2 or t > ๐ก๐ผ/2 Where ๐ก๐ผ ๐๐๐ ๐ก๐ผ/2 are based on ′๐ − 1′ degrees of freedom. Note: The calculated value of ‘t’ is less than the tabulated ‘t-value’ for ๐ degrees of freedom (df), accept H0. i.e., the calculated t < tabulated t at level of significance. Problem 1: Scientists need to be able to detect small amounts of contaminants in the environment. As a check on current capabilities, measurements of lead content (๐๐/๐ฟ) are taken from twelve water specimens spiked with a known concentration 2.5 2.4 2.9 2.7 2.6 2.9 2.0 2.8 2.2 2.4 2.4 2.0 Test the null hypothesis ๐ = 2.25 against the alternative hypothesis ๐ > 2.25 at the 0.025 level of significance. Solution: Null hypothesis: ๐ป0: ๐ = 2.25 Alternative hypothesis: ๐ป0: ๐ > 2.25 Level of significance: ๐ผ = 0.025 Criterion: reject ๐ป0 if ๐ก > 2.201 Where 2.201 is the value of ๐ก0.025 for ๐ − 1 = 12 − 1 = 11 degrees of freedom. Test Statistic: ๐ก= ๐ฬ − ๐ ๐ √๐ From the given data ๐ฬ = 2.483, ๐ = 0.3129, ๐ = 2.25 Then 2.483 − 2.25 = 2.58 ๐ก= 0.3129 √12 Since calculated ๐ก = 2.58 > 2.201, the null hypothesis must be rejected at level of significance ๐ผ = 0.025. Problem 2: The height of 10 males of a given locality are found to be 70,67,62,68,61,68,70,64,64,66 inches. Is it reasonable to believe that the average height is greater than 64 inches? Solution: Given that ๐ = 10, ๐ฬ = 66, ๐ 2 = ∑(๐๐ −๐ฬ )2 ๐−1 = 10 Null hypothesis: ๐ป0: ๐ = 64 Alternative hypothesis: ๐ป0: ๐ > 64 Level of significance: ๐ผ = 0.05 Test Statistic: since the population standard deviation is not known and ๐ < 30, we use t-test ๐ก= = ๐ฬ − ๐ ๐ √๐ 66 − 64 √10 √10 =2 Since calculated ๐ก = 2 > 1.833, the null hypothesis must be rejected at level of significance ๐ผ = 0.05. i.e., there is no sufficient evidence to believe that the average height is greater than 64 inches. Problem 3: The average breaking strength of the steel rods is specified to be 18.5 thousand pounds. To test this sample of 14 rods were tested. The mean and standard deviation obtained were 17.85 and 1.955 respectively. Is the result of experiment significant? Solution: Given that ๐ = 14, ๐ฅฬ = 17.85, ๐ = 1.955, ๐ = 18.5 Null hypothesis: ๐ป0: ๐ = 18.5 Alternative hypothesis: ๐ป0: ๐ ≠ 18.5 Level of significance: ๐ผ = 0.05 Test Statistic: Since the population standard deviation is not known and ๐ < 30, we use t-test ๐ก= = ๐ฬ − ๐ ๐ √๐ 17.85 − 18.5 = −1.311 1.855 √14 Since calculated ๐ก = −1.311 < 1.771, the null hypothesis accepted at level of significance ๐ผ = 0.05 with 13 df. Test of difference of means: Null hypothesis: ๐ป0: ๐1 − ๐2 = ๐ Test Statistic: ๐= ๐ ฬ ฬ ฬ ๐ − ฬ ฬ ฬ ๐๐ ๐ ๐ √ ๐ 2 ( + ) ๐๐ ๐๐ follows t-distribution with ๐1 + ๐2 − 2 degrees of freedom. where, ๐ 2 = Or ∑(๐ฅ1๐−๐ฅ ฬ ฬ ฬ 1ฬ )2 +∑(๐ฅ2๐−๐ฅ ฬ ฬ ฬ 2ฬ )2 ๐1 +๐2−2 ๐ 2 = ๐1 ๐ 1 2 + ๐2 ๐ 22 ๐1 + ๐2 − 2 Problem 1: Samples of two types of electric bulbs were tested for length of life and the following data were obtained Type 1: ๐1 = 8, ฬ ฬ ฬ ฬ ๐ฅ1 = 1234 โ๐๐ข๐๐ , ๐ 1 = 36 ๐๐๐โ๐๐ Type 2: ๐2 = 7, ฬ ฬ ฬ ฬ ๐ฅ2 = 1036 โ๐๐ข๐๐ , ๐ 2 = 40 ๐๐๐โ๐๐ Is the difference in mean sufficient to warrant that type-1 is superior than Type 2 regarding the length of life? Solution: Given that ฬ ฬ ฬ ฬ ๐1 = 8, ฬ ฬ ฬ ฬ ๐ฅ1 = 1234 โ๐๐ข๐๐ , ๐ 1 = 36 ๐๐๐โ๐๐ , ๐2 = 7, ๐ฅ 2 = 1036 โ๐๐ข๐๐ , ๐ 2 = 40 ๐๐๐โ๐๐ Null hypothesis: ๐ป0: ๐1 = ๐2 Alternative hypothesis: ๐ป0: ๐1 > ๐2 Level of significance: ๐ผ = 0.05 Test Statistic: ๐= ๐ 2 = ๐ ฬ ฬ ฬ ๐ − ๐ ฬ ฬ ฬ ๐ ๐ ๐ √ ๐ 2 ( + ) ๐๐ ๐๐ ๐1 ๐ 1 2 + ๐2 ๐ 22 ๐1 + ๐2 − 2 8 × 362 + 7 × 402 = 1659.07 = 8+7−2 ๐ก= ๐ = 1659.07 (1234 − 1036) = 198 √1659.07 × 0.2678 √1659.07 × (1 + 1) 8 7 198 = = 9.39 √444.39 Follows t-distribution with 13 degrees of freedom. Critical region: The tabulated value of ๐ก = 1.771 and the calculated value of ๐ก = 9.39 i.e., the calculated value of ๐ก > tabulated value of ๐ก so, we reject the null hypothesis ๐ป0 at level of significance 0.05. Decision: There is a statistical evidence that Type 1 is superior than Type 2. Problem 2: The mean height and standard deviation height of 8 randomly chosen soldiers are 166.9 and 8.29 cm respectively. The corresponding values of 6 randomly chosen sailors are 170.3 and 8.50cm respectively. Based on this data, can we conclude that soldiers are, in general, shorter than sailors? Solution: Given that ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ๐1 = 8, ๐ฅ 2 = 170.3, ๐ 2 = 8.50 1 = 166.9, ๐ 1 = 8.29, ๐2 = 6, ๐ฅ Null hypothesis: ๐ป0: ๐1 = ๐2 Alternative hypothesis: ๐ป0: ๐1 < ๐2 Level of significance: ๐ผ = 0.05 Test Statistic: ๐= = ๐ 2 = ๐ ฬ ฬ ฬ ๐ − ๐ ฬ ฬ ฬ ๐ ๐ ๐ √ ๐ 2 ( + ) ๐๐ ๐๐ ๐1 ๐ 1 2 + ๐2 ๐ 22 ๐1 + ๐2 − 2 8 × 8.292 + 6 × 8.502 = 81.940 8+6−2 ๐ก= ๐ = 1659.07 (166.9 − 170.3) √81.940 × (1 + 1) 8 6 = −3.4 √81.940 × 0.2961 = −3.4 √24.262 Follows t-distribution with 12 degrees of freedom. = −0.690 Critical region: The tabulated value of ๐ก = 1.771 and the calculated value of ๐ก = −0.690 i.e., the calculated value of ๐ก < tabulated value of ๐ก so, we accept the null hypothesis ๐ป0 at level of significance 0.05. Decision: There is a statistical evidence that we cannot conclude that soldiers are, in general, shorter than sailors. F-distribution: F-distribution is used to test the equality of the variances of two populations from which two samples have been drawn. Null hypothesis: ๐ป0: ๐1 2 = ๐22 Test statistics: ๐ 1 2 ๐น= 2 ๐ 2 Where, ๐ 1 2 = Note: ๏ง ๏ง ๏ง ∑(๐ฅ1๐−๐ฅ ฬ ฬ ฬ 1ฬ )2 ๐1 −1 ๐๐๐ ๐ 22 = ∑(๐ฅ2๐−๐ฅ ฬ ฬ ฬ 2ฬ )2 ๐2−1 The larger among ๐ 1 2 ๐๐๐ ๐ 22 will be the numerator. Here ′๐น′ follows F-distribution with (๐1 − 1, ๐2 − 1) degrees of freedom. The critical region value is ๐น(๐1 −1,๐2 −1). Level of significance ๐ถ rejection region for testing ๐๐ ๐ = ๐๐ ๐: ๐ป1 ๐12 < ๐22 Rejection ๐ป0 ๐น > ๐น๐ผ,(๐1 −1,๐2−1) Test statistics ๐12 > ๐22 ๐12 ≠ ๐22 ๐ 22 ๐น= 2 ๐ 1 ๐น= ๐น= ๐ 1 2 ๐ 22 ๐น < ๐น๐ผ,(๐1 −1,๐2−1) ๐ ๐ 2 ๐ ๐ 2 ๐น ≠ ๐น๐ผ,(๐1 −1,๐2−1) Problem 1: It is desired to determine whether there is less variability in the silver plating done by company 1 than in that done by company 2. If independent random samples of size 12 of the two companies work yield ๐ 1 = 0.035 mil and ๐ 2 = 0.062 mil, test the null hypothesis ๐1 2 = ๐22 against the alternative hypothesis ๐1 2 < ๐2 2 at the 0.05 level of significance. Solution: Null hypothesis: ๐ป0: ๐1 2 = ๐22 Null hypothesis: ๐ป0: ๐1 2 < ๐22 Level of significance: ๐ผ = 0.05 Reject null hypothesis ๐ป0, if ๐น > ๐น๐ผ,(๐1 −1,๐2 −1) i.e., ๐น > ๐น0.05, Test statistics: Here, ๐ 1 2 > ๐ 22 ๐น > ๐น0.05, (11,11) = 2.85 ๐ 12 = 0.0622, ๐ 22 = 0.0352 (12−1,12−1) ๐ 22 ๐น= 2 ๐ 1 0.0622 = 3.14 = 0.0352 Since ๐น = 3.14 > 2.85, the null hypothesis must be rejected. Problem 2: With reference to the example dealing with the heat-producing capacity of coal from two mines ๐1 : ๐2: 8130 8350 8070 8390 7950 7900 8140 7920 7840 Use the 0.01 level of significance to test whether it is reasonable to assume that the variances of the two populations sampled are equal. Solution: Null hypothesis: ๐ป0: ๐1 2 = ๐22 Null hypothesis: ๐ป0: ๐1 2 ≠ ๐22 Level of significance: ๐ผ = 0.01 Reject null hypothesis ๐ป0, if ๐น > ๐น๐ผ,(๐1 −1,๐2 −1) i.e., ๐น > ๐น0.01, ๐น > ๐น0.01, Test statistics: Here, ๐ 1 2 > ๐ 22 ๐คโ๐๐๐, (4,5) = 11.39 ๐ 1 2 = 15750, ๐ 2 2 = 10920 ๐น= ๐ 1 2 ๐ 22 (5−1,6−1) 157502 = = 1.44 109202 Since ๐น = 1.44 < 11.4, the null hypothesis is accepted. Problem 3: In one sample of 10 observations from a normal population, the sum of the squares of the deviations of the sample values from the sample mean is 102.4 and in another sample of 12 observations from another normal population, the sum of the squares of the deviations of the sample values from the sample mean is 120.5. examine whether the two normal populations have the same variance. Solution: Given that ๐1 = 10, ๐2 = 12 ∑(๐ฅ − ๐ฅฬ )2 = 102.4, ∑(๐ฆ − ๐ฆฬ )2 = 120.5 ๐ 1 2 = ๐ 22 = Null hypothesis: ๐ป0: ๐1 2 = ๐22 ∑(๐ฅ − ๐ฅฬ )2 102.4 = = 11.37 ๐1 − 1 10 − 1 ∑(๐ฆ − ๐ฆฬ )2 120.5 = = 10.95 ๐2 − 1 12 − 1 Level of significance: ๐ผ = 0.05 Reject null hypothesis ๐ป0, if ๐น > ๐น๐ผ,(๐1 −1,๐2 −1) i.e., ๐น > ๐น0.01, Test statistics: Here, ๐ 1 2 > ๐ 22 ๐น > ๐น0.05, (9,11) ๐น= ๐ 1 2 ๐ 22 = 2.90 (10−1, 12−1) ๐คโ๐๐๐, ๐ 1 2 = 11.37, ๐ 2 2 = 10.95 11.372 = 1.038 = 10.952 Since ๐น = 1.038 < 2.90, the null hypothesis is accepted. Chi-square distribution (or) ๐๐ − ๐ ๐๐๐๐๐๐๐๐๐๐๐: The sum of k independent squared standard normal variables is Chi-square random variable with ‘k’degrees of freedom i.e., ๐ 2 = ๐1 2 + ๐22 + ๐32 +. . . +๐๐ 2. ๏ท ๏ท The curve is non-symmetrical and skewed to the right The curve differs for each degrees of freedom. Applications: 1. Hypothesis concerning one variance 2. Goodness of fit 3. Test for independence of attributes 1. Hypothesis concerning one variance : Null hypothesis ๐ฏ๐: ๐ 2 = ๐02 Test statistics: Where ๐ is the sample size ๐2 = (๐ − 1)๐ 2 ๐02 ๐ 2 is the sample variance ๐02 is the value of ๐ 2 given by null hypothesis. The degrees of freedom of a ๐ 2 −distribution is ′๐ − 1′. Critical region: ๐ฏ๐ Reject ๐ฏ๐ ๐ 2 < ๐0 2 ๐ 2 < ๐ 21−๐ผ ๐ 2 ≠ ๐0 2 ๐ 2 < ๐ 21−๐ผ/2 ๐๐ ๐ 2 > ๐ 21−๐ผ/2 ๐ 2 > ๐0 2 ๐ 2 > ๐ 21−๐ผ Problem: A manufacturer of car batteries claims that the life of the company’s batteries as approximately normally distributed with a standard deviation equal to 0.9 year. If a random sample of 10 of these batteries has a standard deviation of 1.2 years do you think that ๐ > 0.9 year? Use a 0.05 level of significance. Solution: Null hypothesis ๐ฏ๐: ๐ 2 = 0.81 Alternative hypothesis ๐ฏ๐: ๐ 2 > 0.81 Level of significance: ๐ผ = 0.05 Test statistics: Standard deviation is ๐ = 1.2, then variance is ๐ 2 = 1.44 The degrees of freedom is ๐ − 1 = 10 − 1 = 9 ๐02 = 0.81 ๐2 = (๐ − 1)๐ 2 (10 − 1)1.44 = = 16 ๐02 0.81 The tabulated value of ๐ 2 for 9 degrees of freedom at ๐ผ = 0.05 is 16.919. So null hypothesis is accepted. ๐ 2 = 16 < 16.919 2. Goodness of fit: ๏ง ๏ง ๏ง Suppose we are given a set of observed frequencies obtained under some experiment and we want to test the experimental reults support a particular hypothesis or theory. Karl Pearson developed a test for testing the significance of discrepency between experimental (observed values) values and theoretical values (expected values) obtained under some theory or hypothesis. This test is known as “Chi-square test of goodness of fit”. ๐2 ๐ = ∑[ ๐=1 (๐๐ − ๐ธ๐ )2 ] ๐ธ๐ The degrees of freedom (df) for Chi-square distribution is ′๐ − 1′. Note: If the data is given in series of ′๐′ numbers, then 1. In case of Binomial distribution, ๐๐ = ๐ − 1 2. In case of Poisson distribution, ๐๐ = ๐ − 2 3. In case of Normal distribution, ๐๐ = ๐ − 3. Problem 1: The number of automobile accidents per week in a certain community are as follows: 12,8,20,2,14,10,15,6,9,4. Are these frequencies in agreement with the belief that accident conditions were the same during this 10week period. Solution: Expected frequency of accidents each week = 100 10 = 10 Null hypothesis ๐ฏ๐: the accident conditions were the same during the 10week period Observed frequency (๐ถ) 12 8 20 2 14 10 15 6 9 4 100 Expected frequency (๐ฌ) ๐ถ−๐ฌ 10 10 10 10 10 10 10 10 10 10 100 2 -2 10 -8 4 0 5 -4 -1 -6 (๐ถ − ๐ฌ)๐ ๐ฌ 0.4 0.4 10 6.4 1.6 0 2.5 1.6 0.1 3.6 26.6 ๐2 = ∑ [ Calculated ๐ 2 = 26.6 (๐ถ − ๐ฌ)๐ ] ๐ฌ Here ๐ = 10 observations are given, the degrees of freedom is ๐ − 1 = 10 − 1 = 9 Tabulated ๐ 2 = 16.919 at 0.05 level of significance. Since calculated ๐ 2 > tabukated ๐ 2 Therefore, null hypothesis is rejected. Problem 2: A sample analysis of examination results of 500 students was made. It was found that 220 students had failed. 170 had secured a thrd class, 90 were placed in second class and 20 got a first class. Do these figures commensurate with the general examination result which is in the ratio of 4:3:2:1 for the various ctegories respectively. Solution: Null hypothesis ๐ฏ๐: the observed results commensurate with the general examination results. Expected frequencies are in the ratio of 4:3:2:1. Total frequency = 500. If we divide the total frequency 500 in the ratio 4:3:2:1, we get the expected frequencies as 200,150,100,50. Class Failed Third Second First Observed frequency (๐ถ) 220 170 90 20 Expected frequency (๐ฌ) ๐ถ−๐ฌ 200 150 100 50 20 20 -10 -30 (๐ถ − ๐ฌ)๐ ๐ฌ 2 2.667 1 18 500 500 ๐2 = ∑ [ Calculated ๐ 2 = 23.667 23.667 (๐ถ − ๐ฌ)๐ ] = 23.667 ๐ฌ Here ๐ = 4 observations are given, the degrees of freedom is ๐ − 1 = 4 − 1 = 3 Tabulated ๐ 2 = 7.815 at 0.05 level of significance. Since calculated ๐ 2 >tabukated ๐ 2 Therefore, null hypothesis is rejected. Problem 3: A pair of dice are thrown 360 times and the frequency of each sum is indicated below: Sum 2 Frequency 8 3 24 4 35 5 37 6 44 7 65 8 51 9 42 10 26 11 14 12 14 Would you say that the dice are fair on the basis of the Chi-square test at 0.05 level of significance? Solution: Null hypothesis ๐ฏ๐: The dice are fair. Alternative hypothesis ๐ฏ๐: The dice are not fair. Level of significance: 0.05 ๐ = 11 The probabilities of getting a sum 2,3,4,5,6,7,8,9,10,11 and 12 are 2 ๐ ๐(๐) 1/36 3 2/36 4 3/36 5 4/36 6 5/36 7 6/36 8 5/36 9 4/36 10 3/36 11 2/36 12 1/36 Sum 2 3 4 5 6 7 8 9 10 11 12 Observed frequency (๐ถ) Calculated ๐ 2 = 7.445 8 24 35 37 44 65 51 42 26 14 14 360 Expected frequency (๐ฌ) ๐ฌ = ๐๐๐. ๐(๐) 10 20 30 40 50 60 50 40 30 20 10 360 ๐2 = ∑ [ (๐ถ − ๐ฌ)๐ 4 16 25 9 36 25 1 4 16 36 16 (๐ถ − ๐ฌ)๐ ๐ฌ 0.4 0.8 0.833 0.225 0.72 0.417 0.02 0.1 0.53 1.8 1.6 7.445 (๐ถ − ๐ฌ)๐ ] = 7.445 ๐ฌ Here ๐ = 11 observations are given, the degrees of freedom is ๐ − 1 = 11 − 1 = 10 Tabulated ๐ 2 = 19.675 at 0.05 level of significance. Since calculated ๐ 2 < tabukated ๐ 2 Therefore, null hypothesis is accepted. 3. Chi-square test for independence of attributes: In general, an attribute means a quality or characteristic. Ex: drinking, smoking, blindness, beauty, etc. An attribute may be marked by its presence (position) or absence in a number of a given population. Let us consider two attributes A and B. A is divided into two classes and B is divided in two classes. The various cell frequencies can be expressed in the following table known as 2x2 contingency tale. ๐ด ๐ต ๐ ๐ ๐ ๐ ๐ ๐ ๐+๐ ๐ ๐ ๐+๐ ๐+๐ ๐+๐ ๐ The expected frequencies are given by ๐ธ(๐) = ๐ธ(๐) = (๐ + ๐)(๐ + ๐) ๐ (๐ + ๐)(๐ + ๐) ๐ ๐+๐ ๐ธ(๐) = ๐ธ(๐) = (๐ + ๐)(๐ + ๐) ๐ (๐ + ๐)(๐ + ๐) ๐ ๐+๐ ๐+๐ ๐+๐ ๐ (total frequency) Note: In this Chi-square test, we test if two attributes A and B under consideration are independent or not. Null hypothesis ๐ฏ๐: Attributes are independent. Degrees of freedom: ๐๐ = (๐ − 1)(๐ − 1) Where, ๐ = number of rows ๐ = number of columns Problems: 1. On the basis of information given below about the treatment of 200 patients suffering from a disease, state whether the new treatment is comparatively superior to the conventional treatment. New Conventional Favorable 60 40 Not favorable 30 70 Total 90 110 Solution: Null hypothesis ๐ฏ๐: no difference between new and conventional treatment (or) new and conventional treatment are independent. Degrees of freedom: ๐๐ = (๐ − 1)(๐ − 1) = (2 − 1)(2 − 1) = 1 Where, ๐ = number of rows=2 ๐ = number of columns=2 The expected frequencies are (90)(100) = 45 200 (100)(110) = 55 200 100 (90)(100) = 45 200 (100)(110) = 55 200 100 90 110 200 Calculation of ๐ 2 Observed frequency (๐ถ) 60 30 40 70 200 Expected frequency (๐ฌ) (๐ถ − ๐ฌ)๐ 45 45 55 55 200 225 225 225 225 ๐2 (๐ถ − ๐ฌ)๐ ๐ฌ 5 5 4.09 4.09 18.18 (๐ถ − ๐ฌ)๐ = ∑[ ] = 18.18 ๐ฌ Calculated value of ๐ 2 = 18.18. Tabulated value of ๐ 2 = 3.841 at 0.05 level of significance with 1 degrees of freedom. Since the calculated ๐ 2 > ๐ก๐๐๐ข๐๐๐ก๐๐ ๐ 2.So, we reject the null hypothesis at 0.05 level of significance. Problem 2: Given the following contingency table for hair color and eye color. Find the value of ๐ 2. Is there good association between two? Eye color Blue Grey Brown Total Hair color Fair 15 20 25 60 Brown 5 10 15 30 Black 20 20 20 60 Solution: Null hypothesis ๐ฏ๐: the two attributes, hair and eye color are independent. Total 40 50 60 150 Degrees of freedom: ๐๐ = (3 − 1)(3 − 1) = 4 Where, ๐ = number of rows=3 ๐ = number of columns=3 The expected frequencies are (60)(40) = 16 150 (30)(40) =8 150 (60)(40) = 16 150 40 (30)(60) = 12 150 (60)(60) = 24 150 60 (60)(50) = 20 150 (30)(50) = 10 150 60 30 (60)(60) = 24 150 (60)(50) = 20 150 50 60 150 Calculation of ๐ 2 Observed frequency (๐ถ) 15 5 20 20 10 20 25 15 20 Expected frequency (๐ฌ) (๐ถ − ๐ฌ)๐ 16 8 16 20 10 20 24 12 24 1 8 16 0 0 0 1 9 16 ๐2 = ∑ [ (๐ถ − ๐ฌ)๐ ๐ฌ 0.0625 1.125 1 0 0 0 0.042 0.75 0.665 3.6457 (๐ถ − ๐ฌ)๐ ] = 3.6457 ๐ฌ The tabulated value of ๐ 2 at 0.05 level of significance for degrees of freedom 4 is 9.488. Since the calculated ๐ 2 < ๐ก๐๐๐ข๐๐๐ก๐๐ ๐ 2. So, we accept the null hypothesis at 0.05 level of significance. i.e., the hair color and eye color are independent. Design experiments: ๏ง ๏ง When comparing means across two samples, we use Z-test or t-test. If more than two samples are test for their means, we use ANOVA. ANOVA: Analysis of Variance is a hypothesis testing technique used to test the equality of two or more population means by examining the variances of samples that are taken. Assumptions of ANOVA: ๏ง ๏ง ๏ง All populations involved follow a normal distribution. All populations have the same variances. The samples are randomly selected and independent of one another or the observations are independent. Types of ANOVA: 1. One-way ANOVA: Completely Randomized Design (CRD) 2. Two-way ANOVA: Randomized Based Design (CBD) 3. Three-way ANOVA: Latin Square Design (LSD) I. Scheme for one-way classification Randomized Design (CRD): Sample-1 Sample-2 . . Observations Mean ๐ฆ11 ,๐ฆ12 , . . . , ๐ฆ1๐1 ๐ฆ1 ฬ ฬ ฬ ๐ฆ21 ,๐ฆ22 , . . . , ๐ฆ2๐2 ๐ฆ2 ฬ ฬ ฬ . . . . or Completely Sum of squares ๐1 2 ∑(๐ฆ1๐ − ๐ฆ ฬ ฬ ฬ ) 1 ๐=1 ๐2 2 ∑(๐ฆ2๐ − ๐ฆ ฬ ฬ ฬ ) 2 ๐=1 . . . Sample-i . . . . Sample-k . ๐ฆ๐1 ,๐ฆ๐2 , . . . , ๐ฆ๐๐๐ . ๐ฆฬ ๐ . . . . . . ๐ฆ๐1,๐ฆ๐2 , . . . , ๐ฆ๐๐๐ ๐ฆ๐ ฬ ฬ ฬ ๐๐ 2 ∑(๐ฆ๐๐ − ๐ฆฬ ๐ ) ๐=1 ๐๐ . . . 2 ∑(๐ฆ๐๐ − ๐ฆ ฬ ฬ ฬ ) ๐ ๐=1 Here, the sum of all the observations (grand total) ๐ . ๐๐ ๐บ = ∑ ∑ ๐ฆ๐๐ Total sample size is ๐=1 ๐=1 ๐ = ∑๐๐=1 ๐๐ The overall sample mean (or grand mean) is ๐ฆฬ = Each observation ๐ฆ๐๐ will be de composed as ๐ ๐ ∑๐ ๐=1 ∑๐=1 ๐ฆ๐๐ ∑๐ ๐=1 ๐๐ = ๐บ ๐ ๐ฆ๐๐ = ๐ฆฬ + (๐ฆ ฬ ฬ ฬ ฬ ) + (๐ฆ๐๐ − ๐ฆฬ ) ๐ − ๐ฆ ๐ Taking sum of squares as measure of variation, we have to obtain Sum of square between sample (SSB) ๐ ๐๐๐ต = ∑ ๐๐ ( ฬ ฬ ฬ ฬ ๐ฆ๐ − ๐ฆฬ )2 ๐=1 Or we can say sum of the squared deviations of sample means from general mean (variation between sample). Sum of squared deviation of variates from the corresponding sample means (variation within samples) ๐ ๐๐ ๐๐๐ = ∑ ∑ (๐ฆ๐๐ − ฬ ฬ ฬ ๐ฆ๐ ) ๐=1 ๐=1 2 Total variation or Total sum of squares ๐๐ ๐ 2 ฬ ) ๐๐๐ = ∑ ∑ (๐ฆ๐๐ − ๐ฆ ๐=1 ๐=1 Relation between all sum of squares ๐๐๐ = ๐๐๐ + ๐๐๐ต Short cut formula: ๐๐ ๐ ๐๐๐ = ∑ ∑ ๐ฆ๐๐ 2 − ๐ถ ๐=1 ๐=1 ๐ ๐๐๐ต = ∑ ๐=1 ๐๐ 2 ๐๐ – ๐ถ Where, ๐ถ is called the correction factor for the mean is given by ๐ถ= Test statistics: ๏ง ๐บ2 ๐ ๐ , ๐ = ∑ ๐๐ , ๐=1 ๐๐ ๐๐ = ∑ ๐ฆ๐๐ ๐=1 To test the ๐ป0that ๐พ population mean is equal, we shall compare two estimates of ๐ 2. One based on the variation between the sample mean. One based on the variation within the sample mean. ๏ง Each sum of squares first converted to a mean square ๐๐๐ ๐๐ ๐๐๐๐๐๐๐ ๐๐๐๐ง ๐ฌ๐ช๐ฎ๐๐ซ๐ = ๐ ๐๐๐๐๐๐ ๐๐ ๐๐๐๐๐ ๐๐ Mean of sum of squares between sample ๐๐๐ = 2 ฬ ฬ ฬ ฬ ฬ ∑๐๐=1 ๐๐ (๐ฆ ๐บ๐บ๐ฉ ๐ − ๐ฆ) = ๐ซ๐ญ๐๐๐๐๐๐๐ ๐ฒ− ๐ Mean sum of squares within sample ๐ ๏ง Test statistic: 2 ๐ (๐ฆ − ฬ ฬ ฬ ฬ ∑๐๐=1 ∑๐=1 ๐บ๐บ๐พ ๐๐ ๐ฆ๐ ) ๐๐๐ = = ๐ซ๐ญ๐๐๐๐๐๐ ๐ต−๐ฒ ๐ญ= ๐ด๐บ๐ฉ ๐ด๐บ๐พ F-distribution follows ๐ฒ − ๐ and ๐ต − ๐ฒ degrees of freedom. ANOVA table: Source of variation Between groups Within groups Total Degrees of freedom ๐ฒ− ๐ ๐ต−๐ฒ Sum of squares Mean squares SSB SSW MSB MSW ๐ต−๐ SST Decision: If ๐น > ๐น๐ผ,(๐−1,๐−๐พ), reject the null hypothesis ๐ป0. Problem 1: Compare the means of these groups I 1 2 5 II 2 4 2 III 2 3 4 II 2 4 2 8 III 2 3 4 9 Solution: I 1 2 5 Total = 8 ๐น ๐น = ๐๐๐ต ๐๐๐ Null hypothesis ๐ฏ๐ : ๐1 = ๐2 = ๐3 Alternative hypothesis ๐ฏ๐ : At least there is one difference among the means. Level of significance: ๐ผ = 0.05 Degrees of freedom: ๐ซ๐ญ๐๐๐๐๐๐๐ = ๐ฒ − ๐ = ๐ − ๐ = ๐ ๐ซ๐ญ๐๐๐๐๐๐ = ๐ต − ๐ฒ = ๐ − ๐ = ๐ ๐น๐ผ,(๐−1,๐−๐พ) = ๐น0.05,(2,6) = 5.14 sum of all the observations (grand total) = ๐บ ๐๐ ๐ ๐บ = ∑ ∑ ๐ฆ๐๐ = 1 + 2 + 5 + 2 + 4 + 2 + 2 + 3 + 4 = 25 Correction factor is ๐ถ = ๐ ๐๐ 2 ๐บ ๐ ๐=1 ๐=1 = 625 9 = 69.444 ๐๐๐ = ∑ ∑ ๐ฆ๐๐ 2 − ๐ถ = (12 + 22 + 52 + 22 + 42 + 22 + 22 + 32 + 42 ) − 69.444 ๐=1 ๐=1 = 13.556 Sum of the squares between ๐๐๐ต = ∑๐๐=1 ๐๐2 ๐๐ 82 –๐ถ =( + 3 82 3 + 92 3 ) − 69.444 = 69.667 − 69.444 = 0.223 Sum of the squares within ๐๐๐ = ๐๐๐ + ๐๐๐ต Then, ๐๐๐ = ๐๐๐ − ๐๐๐ต = 13.556 − 0.223 = 13.333 Mean sum of the squares ๐๐๐ต = ๐๐๐ = ๐บ๐บ๐ฉ ๐ซ๐ญ๐๐๐๐๐๐๐ ๐บ๐บ๐พ ๐ซ๐ญ๐๐๐๐๐๐ = = ๐. ๐๐๐ ๐ ๐๐. ๐๐๐ ๐ = ๐. ๐๐๐ = ๐. ๐๐๐ ANOVA table: Source of variation Degrees of freedom Sum of Squares (SS) Between groups Within groups ๐ฒ−๐ =๐−๐ =๐ ๐ต−๐ฒ =๐−๐ =๐ ๐ต−๐ =๐−๐ =๐ SSB=0.223 SSW=13.333 Total Mean Squares (MS) MSB=0.115 MSW=2.222 ๐น ๐น= ๐๐๐ต = 0.0517 ๐๐๐ SST=13.356 Since, calculated F < tabulated F i.e., 0.0517<5.14. So, we accept the Null hypothesis. i.e., there is no significant difference between the means of groups. Problem 2: In a tin coating laboratory, the weights of 12 disks and that results are as follows: Laboratory A 0.25 0.27 0.22 0.30 0.27 0.28 0.32 0.24 0.31 0.26 0.21 0.28 Construct an ANOVA table. Laboratory B 0.18 0.28 0.21 0.23 0.25 0.20 0.27 0.19 0.24 0.22 0.29 0.16 Laboratory C 0.19 0.25 0.27 0.24 0.18 0.26 0.28 0.24 0.25 0.20 0.21 0.19 Laboratory D 0.23 0.30 0.28 0.28 0.24 0.34 0.20 0.18 0.24 0.28 0.22 0.21 Solution: ๐ฒ = ๐, ๐ต = ๐๐ Level of significance: ๐ผ = 0.05 Degrees of freedom: ๐ซ๐ญ๐๐๐๐๐๐๐ = ๐ฒ − ๐ = ๐ − ๐ = ๐ ๐ซ๐ญ๐๐๐๐๐๐ = ๐ต − ๐ฒ = ๐๐ − ๐ = ๐๐ Sum of all the observations (grand total) = ๐บ Correction factor is ๐ถ = ๐ ๐๐ 2 ๐บ ๐ = ๐ ๐๐ ๐บ = ∑ ∑ ๐ฆ๐๐ = 11.69 ๐=1 ๐=1 11.692 = 2.8470 48 ๐๐๐ = ∑ ∑ ๐ฆ๐๐ 2 − ๐ถ = (0.252 + 0.272 +. . . +0.212 ) − 2.8470 = 0.0809 ๐=1 ๐=1 Sum of the squares between ๐๐๐ต = ∑๐๐=1 ๐๐2 ๐๐ 3.212 –๐ถ =( 12 + 2.722 12 + 2.762 12 + 32 12 ) − 2.8470 = 0.0130 Sum of the squares within ๐๐๐ = ๐๐๐ + ๐๐๐ต Then, ๐๐๐ = ๐๐๐ − ๐๐๐ต = 0.0809 − 0.0130 = 0.0679 Mean sum of the squares ๐ด๐บ๐ฉ = ๐บ๐บ๐ฉ ๐ซ๐ญ๐๐๐๐๐๐๐ ๐ด๐บ๐พ = ๐บ๐บ๐พ ๐ซ๐ญ๐๐๐๐๐๐ = = ๐. ๐๐๐๐ ๐−๐ ๐. ๐๐๐๐ ๐๐ − ๐ = ๐. ๐๐๐๐ = ๐. ๐๐๐ ANOVA table: Source of variation Between groups Within groups Total Degrees of freedom ๐ฒ−๐ =๐−๐ =๐ ๐ต − ๐ฒ = ๐๐ − ๐ = ๐๐ ๐ต − ๐ = ๐๐ − ๐ = ๐๐ Sum of Squares (SS) SSB=0.0130 SSW=0.0679 Mean Squares ๐น (MS) ๐๐๐ต MSB=0.0043 MSW=0.0015 ๐น = ๐๐๐ = 2.87 SST=0.0809 ๐น๐ผ,(๐−1,๐−๐พ) = ๐น0.05,(3,44) = 2.84 Since, calculated F < tabulated F i.e., 2.87>2.84. So, we reject the Null hypothesis. i.e., we conclude that the laboratories are not obtaining consistent results. Two-Way ANOVA: Two-way ANOVA compares the means of population that are classified in two ways or the mean responses in two-factor experiments. Randomized Block Design: The arrangement of two-way classification. Treatment 1 Treatment 2 . . . Treatment i . ๐ต1 ๐ฆ11 ๐ฆ21 . . . ๐ฆ๐1 . ๐ต2 ๐ฆ12 ๐ฆ22 ๐ฆ๐2 Blocks (columns) ... ๐ต๐ ... ๐ฆ1๐ … … ๐ฆ2๐ … … ๐ฆ๐๐ … ๐ต๐ ๐ฆ1๐ ๐ฆ2๐ ๐ฆ๐๐ Means Total ๐ฆฬ ฬ ฬ ฬ ๐1. 1. ๐ฆ2.ฬ ฬ ฬ ฬ ๐2. ๐ฆ๐ . ฬ ฬ ฬ ๐๐ . . . Treatment C Means Total Where, . . ๐ฆ๐ถ1 ๐ฆ.1ฬ ฬ ฬ ฬ ๐.1 ๐ฆ๐ถ2 ๐ฆ.2ฬ ฬ ฬ ฬ ๐.2 … ๐ฆ๐ถ๐ ๐ฆ.๐ ฬ ฬ ฬ ๐.๐ … ๐ฆ๐ถ๐ ๐ฆ.๐ ฬ ฬ ฬ ๐.๐ ฬ ฬ ฬ ฬ ๐ฆ ๐ถ. ๐ฆฬ ฬ ฬ ฬ . . ๐๐ถ. ๐. . ๐ฆ๐๐ – the observation pertaining to the ith treatment and the jth block (column) ๐ฆ ฬ ฬ ฬ ๐ . – mean of the ‘r’ observations for ith treatment ฬ ฬ ฬ ๐ฆ ๐ . – mean of the ‘C’ observations for jth block ๐ฆ ฬ ฬ ฬ ฬ . . – the grand mean of all ‘rC’ observations. Note: The dot is used for the mean is obtained by summing over the subscripts. Model equation for randomized block design: ๐ฆ๐๐ = ๐ + ๐ผ๐ + ๐ฝ๐ + ๐๐๐ , for ๐ = 1,2, . . . , ๐ถ where, ๐ = 1,2, . . . , ๐ ๐ = grand mean ๐ผ๐ = mean, due to the effect of the ith treatment or between the sample ๐ฝ๐ = mean, due to the effect of the jth block ๐๐๐ = error, within the sample deviation. Hypothesis for two-way ANOVA: ๐ป0 : ๐ผ1 = ๐ผ2 =. . . = ๐ผ๐ถ , ๐ป1 : ๐ผ1 ≠ ๐ผ2 ≠. . . ≠ ๐ผ๐ถ ๐ป0 : ๐ฝ1 = ๐ฝ2 =. . . = ๐ฝ๐ , โถ ๐ป1 : ๐ฝ1 ≠ ๐ฝ2 ≠. . . ≠ ๐ฝ๐ Or ๐ป0 : ๐1 = ๐2 =. . . = ๐๐ถ (columns) ๐ป0 : ๐1 = ๐2 =. . . = ๐๐ (rows) Or There is at least one mean in the columns which differ from others. Also, in rows. Degrees of freedom: ๐ท๐น(๐๐๐๐ข๐๐ ๐๐ ๐ก๐๐๐๐ก๐๐๐๐ก๐ ) = ๐ถ − 1 ๐ท๐น(๐๐๐ค ๐๐ ๐๐๐๐๐) = ๐ − 1 ๐ท๐น(๐๐๐๐๐ ๐๐ ๐ค๐๐กโ๐๐ ๐ ๐๐๐๐๐) = ๐ถ๐ − 1 Critical values: ๐น๐ผ, (๐ถ−1,(๐ถ−1)(๐−1)) and ๐น๐ผ, (๐−1,(๐ถ−1)(๐−1)) Like one-way ANOVA, we estimate for the ๐ 2 comparing Variance among treatments (or between sample) Variance among blocks, and Measuring the experimental error or variation within samples. Identity for analysis of two-way ANOVA classification: ๐ถ ๐ ๐ถ 2 ๐ ๐ถ 2 2 ฬ ฬ ฬ ..) = ∑ ∑ (๐ฆ๐๐ − ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ฬ ๐ฆ๐.ฬ − ๐ฆ ∑ ∑ ( ๐ฆ๐๐ − ๐ฆ .๐ + ๐ฆ .. ) + ๐ ∑( ๐ฆ๐. − ๐ฆ.. ) ๐=1 ๐=1 ๐ ๐=1 ๐=1 ๐=1 2 ฬ ฬ ฬ .. ) + ๐ถ ∑ (ฬ ฬ ฬ ฬ ๐ฆ.๐ − ๐ฆ ๐=1 Each observation ๐ฆ๐๐ will be decomposed as ๐ฆ๐๐ = ๐ฆฬ .. + (๐ฆฬ ๐. − ๐ฆฬ ..) + (๐ฆ๐๐ − ๐ฆฬ ๐. − ๐ฆ ฬ ฬ ฬ .๐ + ๐ฆฬ ..) Sum of squares for two-way ANOVA: Treatment sum square, ๐๐(๐๐) = ๐ ∑๐ถ๐=1(๐ฆฬ ๐. − ๐ฆฬ ..)2 Or Short cut formula ๐บ๐บ(๐ป๐) = ∑๐ช๐=๐ ๐ป๐. ๐ ๐ − ๐ช๐๐๐๐๐๐๐๐๐ ๐๐๐๐๐๐ 2 ฬ ฬ ฬ ฬ .. ) Block sum square, ๐๐(๐ต๐) = ๐ถ ∑๐๐=1(๐ฆ .๐ − ๐ฆ Or Short cut formula ๐บ๐บ(๐ฉ๐) = ∑๐๐=๐ ๐ป.๐ ๐ ๐ − ๐ช๐๐๐๐๐๐๐๐๐ ๐๐๐๐๐๐ 2 Error sum of square, ๐๐๐ธ = ∑๐ถ๐=1 ∑๐๐=1(๐ฆ๐๐ − ๐ฆฬ ๐. − ๐ฆ ฬ ฬ ฬ .๐ + ๐ฆฬ ..) 2 Total sum of square, ๐๐๐ = ∑๐ถ๐=1 ∑๐๐=1(๐ฆ๐๐ − ๐ฆฬ .. ) Short cut formula ๐ช ๐ ๐ ๐บ๐บ๐ป = ∑ ∑(๐๐๐ − ๐ฬ ..) − ๐ช๐๐๐๐๐๐๐๐๐ ๐๐๐๐๐๐ ๐=๐ ๐=๐ Where, correction factor is given by ๐ช = ๐ป.. ๐ ๐ช๐ ๐๐ . = the sum of the ๐ observations for the ith treatment ๐.๐ = the sum of the ๐ถ observations for the jth block ๐.. = the grand total of all observations F-ratio for treatment or between sample ๐ญ๐ป๐ ๐บ๐บ(๐ป๐) ) ๐ด๐บ(๐ป๐) ๐ช−๐ = = ๐บ๐บ๐ฌ ๐ด๐บ๐ฌ (( ) ๐ช − ๐)(๐ − ๐) ( Decision: reject for ๐ป0 , if ๐น๐๐ > ๐น(๐ถ−1,(๐ถ−1)(๐−1)) F-ratio for blocks ๐บ๐บ(๐ฉ๐) ( ) ๐ด๐บ(๐ฉ๐) ๐−๐ ๐ญ๐ฉ๐ = = ๐บ๐บ๐ฌ ๐ด๐บ๐ฌ ) (( ๐ช − ๐)(๐ − ๐) Decision: reject for ๐ป0 , if ๐น๐ต๐ > ๐น๐ผ, Two-way ANOVA table for results (๐−1,(๐ถ−1)(๐−1)) Source of variation Treatments Degrees of freedom ๐−๐ Sum of squares SS(Tr) Blocks ๐ช−๐ SS(Bl) Mean squares ๐๐(๐๐) ๐๐(๐๐) = ๐−1 ๐น ๐น๐๐ ๐๐(๐๐) = ๐๐๐ธ Error (๐ถ − 1)(๐ − 1) ๐๐(๐ต๐) ๐๐(๐ต๐) = ๐ถ −1 SSE ๐๐๐ธ Total (๐ถ๐ − 1) SST = ๐๐๐ธ (๐ − 1)(๐ถ − 1) ๐น๐ต๐ ๐๐(๐ต๐) = ๐๐๐ธ Problem 1: An experiment was designed to study the performance 4 different detergents for cleaning fuel injectors. The following “cleanness” reading were obtained with specially designed equipment for 12 tanks of gas distributed over 3 different models of engines Detergent A Detergent B Detergent C Detergent D Total Detergent A Detergent B Detergent C Detergent D Engine 1 45 47 48 42 182 Engine 1 45 47 48 42 Engine 2 43 46 50 37 176 Engine 2 43 46 50 37 Engine 3 51 52 55 49 207 Engine 3 51 52 55 49 Total 139 145 153 128 565 Looking at the detergents as treatments and the engines as blocks, obtain the appropriate ANOVA table and test the 0.01 level of significance whether there are differences in the detergents or in the engines. Solution: Null hypothesis ๐ป0 : ๐ผ1 = ๐ผ2 = ๐ผ3 = ๐ผ4 = 0 ๐ฝ1 = ๐ฝ2 = ๐ฝ3 = 0 Alternative hypothesis ๐ป1 : ๐ผ1 ≠ ๐ผ2 ≠ ๐ผ3 ≠ ๐ผ4 ≠ 0 ๐ฝ1 ≠ ๐ฝ2 ≠ ๐ฝ3 ≠ 0 The level of significance: ๐ผ = 0.01 ๐ − 1 = 4 − 1 = 3 ๐๐๐ (๐ − 1) = 3 − 1 = 2 (๐ − 1)(๐ − 1) = (4 − 1)(3 − 1) = 6 Reject ๐ป0 for the treatment, if ๐น(๐ก๐) > ๐น0.01, = ๐น0.01, (4−1,(4−1)(3−1)) = ๐น0.01, Reject ๐ป0 for the block, if ๐น(๐ต๐) > ๐น0.01, Calculation: = ๐น0.01, (3−1,(4−1)(3−1)) (๐−1,(๐−1)(๐−1)) (๐−1,(๐−1)(๐−1)) = ๐น0.01, ๐ = 4, ๐ = 3 ๐1. = 139 ๐2. = 145 ๐3. = 153 And (0.01, (3,6)) ๐4. = 128 ๐.1 = 182 (0.01, (2,6)) = 9.78 = 10.92 ๐.2 = 176 ๐.3 = 207 ๐.. = 565 ∑ ∑ ๐ฆ๐๐ 2 = 452 + 472 + 482 + 422 +. . . +492 = 26867 ๐ถ๐๐๐๐๐๐ก๐๐๐ ๐๐๐๐ก๐๐ ๐๐ ๐ถ = ๐ถ ๐ ๐.. 2 ๐๐ = 5652 4×3 = 26602 2 ๐๐๐ = ∑ ∑(๐ฆ๐๐ − ๐ฆฬ .. ) − ๐ถ๐๐๐๐๐๐ก๐๐๐ ๐๐๐๐ก๐๐ ๐=1 ๐=1 ๐๐๐ = (452 + 472 + 482 + 422 +. . . +492) − 26602 = 26867 − 26602 = 265 ๐๐(๐๐) = ∑๐ถ๐=1 ๐๐. 2 ๐ − ๐ถ๐๐๐๐๐๐ก๐๐๐ ๐๐๐๐ก๐๐ 1392 +1452 + 1532 + 1282 = − 26602 = 110.917 3 ∑๐๐=1 ๐.๐2 ๐๐(๐ต๐) = − ๐ถ๐๐๐๐๐๐ก๐๐๐ ๐๐๐๐ก๐๐ ๐ = 1822 + 1762 + 2072 4 − 26602 = 135.167 ๐๐๐ธ = 265 − (111 + 135) = 18.833 Two-way ANOVA table Source of variation Detergents Degrees of freedom ๐−๐ = ๐−๐ =๐ Sum of squares SS(Tr)=110.917 Mean squares ๐น ๐๐(๐๐) ๐น๐๐ ๐๐(๐๐) = ๐๐(๐๐) ๐−1 = 110.917 ๐๐๐ธ = = 36.972 = 11.78 3 Engines ๐−๐ = ๐−๐ =๐ Error Total (๐ − 1)(๐ − 1) = 6 (๐๐ − 1) = (12 − 1) = 11 ๐๐(๐ต๐) ๐๐(๐ต๐) = SS(Bl)=135.167 ๐−1 ๐น๐ต๐ 135.167 = = 67.583 ๐๐(๐ต๐) 2 = ๐๐๐ธ = 21.53 ๐๐๐ธ SSE=18.833 ๐๐๐ธ = (๐ − 1)(๐ − 1) 18.833 = = 3.139 6 SST=264.917 Decision: ๐น(๐ก๐) > ๐น0.01, (๐−1,(๐−1)(๐−1)) ๐น(๐ก๐) > ๐น0.01, (4−1,(4−1)(3−1)) 11.78 > 9.78 Reject the null hypothesis for treatment. ๐น(๐ต๐) > ๐น0.01, (3−1,(4−1)(3−1)) 21.53 > 10.92 Reject the null hypothesis for Blocks. We conclude that there are differences in the effectiveness of the 4 detergents. Also, the differences among the results obtained for the 3 engines are significant. There is an effect due to the engines, so blocking was important. Latin Square Design (LSD) (or) Three-way ANOVA: ๏ท In addition to rows and columns, we need to consider an extra factor known as treatments. ๏ท Every treatment occurs only once in each row and in each column. Such a layout is known as Latin Square Design. Ex: If we are interested in studying the effects of ๐ types of fertilizers on a yield of a certain variety of wheat, we conduct the experiment on a square field with ๐ 2 plots of equal area and associate treatments with different fertilizers; row and column effects with variations in fertility or soil. Procedure of LSD: Null hypothesis: There is no significant difference in the means of columns (Groups), rows (Blocks), and treatments. Alternative hypothesis: There is at least one mean in column which differs from others. Also, there is at least one mean in the rows which differs from others. Similarly, for treatments. Degrees of freedom: ๐ซ๐ญ๐๐๐๐ = ๐ − ๐ ๐ซ๐ญ๐๐๐๐๐๐๐ = ๐ − ๐ ๐ซ๐ญ๐๐๐๐๐๐๐๐๐๐ = ๐ − ๐ ๐ซ๐ญ๐ฌ๐๐๐๐ = (๐ − ๐)(๐ − ๐) Critical region: ๐น(๐−1,(๐−๐)(๐−๐) ) ๐บ = ∑ ∑ ๐ฅ๐๐ Correction factor is ๐ถ. ๐น = Sum of squares total: sum of squares: ๐บ2 ๐ ๐๐๐ = ∑ ∑ ๐ฅ๐๐ 2 − ๐ถ. ๐น ๐ถ๐ 2 − ๐ถ๐น ๐๐๐ถ = ∑ ๐ Where, ๐ถ๐ is the column sum of the jth column. ๐๐๐ = ∑ Where, ๐ ๐ is the row sum of the ith row. ๐ ๐ 2 − ๐ถ๐น ๐ ๐๐๐๐ = ∑ Where, ๐๐ is called the treatment sum of ith treatment. ANOVA table: Source of variation Columns Rows Treatments ๐๐ 2 − ๐ถ๐น ๐ ๐๐๐ธ = ๐๐๐ − ๐๐๐ − ๐๐๐ถ − ๐๐๐๐ Sum of Squares (SS) SSC SSR SSTr Degrees of freedom Mean squares (MS) ๐−1 ๐๐๐ถ ๐−1 ๐−1 ๐−1 ๐๐๐ ๐−1 ๐๐๐๐ ๐−1 ๐ญ ๐น1 = ๐น2 = ๐น3 = ๐๐๐ถ ๐๐๐ธ ๐๐๐ ๐๐๐ธ ๐๐๐๐ ๐๐๐ธ Error SSE (๐ − 1) (๐ − 2) ๐๐๐ธ (๐ − 1) (๐ − 2) Problem: Analyze the variance in the Latin Square Design of yields (in Kgs) of paddy where P, Q, R, S denote the different methods of cultivation S122 Q124 P120 R122 P121 R123 Q119 S123 R123 P122 S120 Q121 Q122 S125 R121 P122 Solution: Null hypothesis: There is no significance difference in the means of columns, rows and treatments (methods of cultivation). Alternative hypothesis: There is at least one mean in the columns which differs from others. Also, there is at least one mean in the rows which are differs from the others. Similarly, for treatments Here, ๐ = 4 Degrees of freedom: ๐ซ๐ญ๐๐๐๐ = ๐ − ๐ = ๐ ๐ซ๐ญ๐๐๐๐๐๐๐ = ๐ − ๐ = ๐ ๐ซ๐ญ๐๐๐๐๐๐๐๐๐๐ = ๐ − ๐ = ๐ ๐ซ๐ญ๐ฌ๐๐๐๐ = (๐ − ๐)(๐ − ๐) = ๐ Level of significance: ๐ถ = ๐. ๐๐ Critical region: ๐น(3,6) = 4.76 Test Statistics: S2 Q4 P0 R2 8 P1 R3 Q-1 S3 6 R3 P2 S0 Q1 6 Q2 S5 R1 P2 10 8 14 0 8 G=30 Treatment Sum: Sum of the treatments are ๐ = 5, ๐ = 6, ๐ = 9, ๐ = 10 ๐บ = 30, ๐ = 16 Correction factor is ๐ถ. ๐น = ๐บ2 ๐ = 302 16 = 56.25 ๐๐๐ = ∑ ∑ ๐ฅ๐๐2 − ๐ถ. ๐น = (22 + 12 + 22 +. . . +22 ) − 56.25 = 92 − 56.25 = 35.75 ๐ ๐ 2 82 142 02 82 ๐๐๐ = ∑ − ๐ถ๐น = + + + = 24.75 ๐ 4 4 4 4 ๐ ๐ถ๐ 2 62 62 62 102 − ๐ถ๐น = + + + = 2.75 ๐๐๐ถ = ∑ 4 4 4 4 ๐ ๐๐๐๐ = ∑ 52 62 92 102 ๐๐ 2 − ๐ถ๐น = + + + − 10.25 = 4.25 4 4 4 4 ๐ ๐๐๐ธ = ๐๐๐ − ๐๐๐ − ๐๐๐ถ − ๐๐๐๐ = 35.75 − 24.75 − 2.75 − 4.25 = 4 Source of variation Columns Rows Treatments Error Sum of Squares (SS) SSC=2.75 SSR=24.75 SSTr=4.25 SSE Degrees of freedom Mean squares (MS) 3 ๐๐๐ถ = 0.917 ๐−1 3 ๐๐๐ = 8.25 ๐−1 3 ๐๐๐๐ = 1.417 ๐−1 6 ๐๐๐ธ (๐ − 1) (๐ − 2) = 0.667 ๐น ๐น1 ๐๐๐ถ ๐๐๐ธ 0.917 = 0.667 = 1.375 = ๐น2 ๐๐๐ ๐๐๐ธ 8.25 = 0.667 = 12.36 = ๐น3 ๐๐๐๐ ๐๐๐ธ 1.417 = 0.667 = 2.124 = Decision: Comparing ๐น1 , ๐น2 , ๐น3 with critical region ๐น(3,6) = 4.76, we accept null hypothesis (columns), accept null hypothesis (treatments), reject null hypothesis (rows).