Usage Standard Error & Rule of Thumb p-value Assumptions Check whether two Assume two groups A & B group means are have similar SSD different not too different in size Probability that test is as extreme or > extreme than observed data if π > 30, 0.2 < π < 0.8 Gaussian distribution Normal Distribution Sign Test Used to test that the difference median is zero between two variables Decide whether group means are different (Proportion) t-test (Means) π 2 and contingency tables Test independence between two variables Assume π independent pairs of observations Assume π independent measurements following a Gaussian distribution. Assume each group same SD. There’s no one-sided or two-sided test for π 2 (Independence) Spearman’s π ranking Calculations SE = SSD √π =√ π(1 − π) π P(ππππ ππ ππππ πππ‘ππ 9π») = P(π‘ = 9, π‘ = 10, π‘ = 1, π‘ = 0) 10 1 10 1 = + + + = 0.021 1024 1024 1024 1024 π − ππ π= √ππ(1 − π) π π(π = π) = ( ) ππ (1 − π)π−π π H0: No difference between the two H1: The two are different π‘= SMπ΄ − SMπ΅ √SEπ΄2 + SEπ΅2 π2 = ∑ , ππ = 2π − 2 (ππππππππ − πΈπ₯ππππ‘ππ)2 πΈπ₯ππππ‘ππ ππ = (πππ€π − 1)(πππ − 1) Check for correlation between two variables Assume π independent pairs of observations (Correlation) 6 ∑ π·π 2 π =1− π(π2 − 1) ππ = π − 2 Sample Mean, π₯ = π₯1 + π₯2 + β― + π₯π π SSD = √ (π₯1 − π₯)2 + (π₯2 − π₯)2 + β― + (π₯π − π₯)2 π−1 SSD is standard deviation of ONE individual from the sample mean SE is the standard deviation of the sample mean from the population Interpretations Example Strong indication that two group means are different if the intervals SMπ΄ ± 1.5 × SEπ΄ and SMπ΅ ± 1.5 × SEπ΅ do not overlap One-sided: Only interested in bias towards H Two-sided: coin is biased 1 1 H1: P(H) > > P(T) H1: P(H) ≠ ≠ P(T) 2 2 Given: π1 ~π(π1 , π 1 ) & π2~π(π2 , π 2 ) independent π1 + π2 ~π(π1 + π2 , √π 12 + π 22 ) Let π~π(102.6,18.5). What is P(π ≤ 120) P(π ≤ 120) = P(π(102.6,18.5) ≤ 120) = P(π(0,18.5) ≤ 17.4) = P(π(0,1) ≤ 0.940) ≈ 0.8264 1 20 20 20 P(W ≥ 14) = ( ) (( ) + ( ) + β― ) 2 14 15 After introducing airbags, no. of casualties in accidents dropped in 14 among 20 countries and gone up in other 6 When given SM, SSD, and n, t-test can be used to decide whether the two means are different. If SSD are different, ttest is not as accurate It was observed that the average PSI on rainy days is lower than the average PSI on sunny days To find Observed F M N 68 64 132 Y 82 130 212 150 194 344 Before 35 38 3 4 After 76 56 8 4 π·π -5 0 25 0 π·π2 Expected F M N 57.56 74.4 132 Y 92.44 119.56 212 150 194 344 43 33 45 52 32 42 6 2 7 8 1 5 58 63 36 48 55 75 5 6 1 2 3 7 1 -4 6 6 -2 -2 1 16 36 36 4 4 The proportion of Samsung versus Apple smartphones owners in Singapore is different than as compared to Malaysia. Do taller students have a higher CAP?