12.07.2015 Views

Course Notes - Department of Mathematics and Statistics

Course Notes - Department of Mathematics and Statistics

Course Notes - Department of Mathematics and Statistics

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Since 1 is excluded there is strong evidence that there is an increasedrisk <strong>of</strong> catching the river blindness. Fred is 95% confident that the oddsare increased by between 1.9 - 3.03 times. This is too much <strong>of</strong> a risk forFred, so he has instructed Carol to avoid the rainforest when planningtheir west african journey.Part IIINow Fred turned his attention to the whether or not married couplestended to be similar heights, since he had split the heights into threecategories he realised he could not deal with this problem using Oddsratio or Relative risk, instead he would have to use Chi-squared. Fredhated calculating Chi-squared by h<strong>and</strong>, not because it was difficult,more that it was time-consuming. He first calculated the expectedvalues <strong>and</strong> put them in the table in square brackets []. Recall theequation for expected values is:E ij = r i×c jnWife HeightsHeights <strong>of</strong> Husb<strong>and</strong> Tall Medium Short TotalTall 20 [16.58] 30 [32.52] 16 [16.90] 66Medium 18 [23.36] 49 [45.83] 26 [23.81] 93Short 14 [12.06] 23 [23.65] 11 [12.29] 4852 102 53 207The next step is to calculate the chi-squared statistic, the formula forthis is:no.<strong>of</strong>rows∑i=1no.<strong>of</strong>columns∑j=1χ 2 = (O ij − E ij ) 2E ijThis generated a Chi-squared statistic <strong>of</strong> 3.064, this needed to be comparedagainst the critical value for a 3 × 3. This has a degree <strong>of</strong> freedom<strong>of</strong> 4, using R qchidist(0.95,4) we get the value <strong>of</strong> 9.487729 as the criticalvalue at 95%. Since our value <strong>of</strong> 3.064 < 9.488 there is no evidence <strong>of</strong>association between the heights <strong>of</strong> the husb<strong>and</strong>s <strong>and</strong> the heights <strong>of</strong> thewives. So those couples that Fred first observed must have just been aco-incidence, an not indicative <strong>of</strong> an overall pattern.165

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!