Chi-Square Presentation - Nikki

download Chi-Square Presentation - Nikki

of 34

Transcript of Chi-Square Presentation - Nikki

  • 8/17/2019 Chi-Square Presentation - Nikki

    1/34

     Tutorial: Chi-Square Tutorial: Chi-Square

    DistributionDistributionPresented by: Nikki NatividadCourse: BIOL 5!" - Biostatisti#s

  • 8/17/2019 Chi-Square Presentation - Nikki

    2/34

    Pur$osePur$ose

     To %easure dis#ontinuous #ate&ori#al'binneddata in (hi#h a nu%ber o) sub*e#ts )all into#ate&ories

    +e (ant to #o%$are our observed data to

    (hat (e e,$e#t to see Due to #han#e. Dueto asso#iation.

    +hen #an (e use the Chi-Square Test.

    ◦  Testin& out#o%e o) /endelian Crosses0 Testin&

    Inde$enden#e 1 Is one )a#tor asso#iated (ithanother.0 Testin& a $o$ulation )or e,$e#ted$ro$ortions

  • 8/17/2019 Chi-Square Presentation - Nikki

    3/34

    2ssu%$tions:2ssu%$tions:

    " or %ore #ate&oriesInde$endent observations

    2 sa%$le si3e o) at least "

    4ando% sa%$lin&2ll observations %ust be used

    or the test to be a##urate0 the

    e,$e#ted )requen#y should be at least5

  • 8/17/2019 Chi-Square Presentation - Nikki

    4/34

    Condu#tin& Chi-SquareCondu#tin& Chi-Square2nalysis2nalysis"6 /ake a hy$othesis based on your basi# biolo&i#al

    question

    76 Deter%ine the e,$e#ted )requen#ies

    86 Create a table (ith observed )requen#ies0 e,$e#ted

    )requen#ies0 and #hi-square values usin& the)or%ula:

    9O-67

    ;6 ind the de&rees o) )reedo%: 9#-"69r-"6

    56 ind the #hi-square statisti# in the Chi-SquareDistribution table

  • 8/17/2019 Chi-Square Presentation - Nikki

    5/34

    ,a%$le ": Testin& )or,a%$le ": Testin& )orPro$ortionsPro$ortions

    LeafCutterAnts

    CarpenterAnts

    BlackAnts

    Total

    Observed 75 "! ">

  • 8/17/2019 Chi-Square Presentation - Nikki

    6/34

    ,a%$le ": Testin& )or,a%$le ": Testin& )orPro$ortionsPro$ortions

    ?7@5 @5AA"

  • 8/17/2019 Chi-Square Presentation - Nikki

    7/34

    ,a%$le ": Testin& )or,a%$le ": Testin& )orPro$ortionsPro$ortions

    Chi-square statisti#: χ2 = 5.991 Our #al#ulatedvalue: χ2 = 1.90

    I) #hi-square statisti# = your #al#ulated value0 then you donot reject  your null hy$othesis There is a si&niE#ant diFeren#e

    that is not due to #han#e

    5AA" = "A ∴ +e do not reject  our null hy$othesis

    LeafCutterAnts

    CarpenterAnts

    BlackAnts

    Total

    Observed 75 "! ">

  • 8/17/2019 Chi-Square Presentation - Nikki

    8/34

    S2S: ,a%$le "S2S: ,a%$le "

    In#luded to )or%at the table

    DeEne your data

    Indi#ate (hatyour (ant in

    your out$ut

  • 8/17/2019 Chi-Square Presentation - Nikki

    9/34

    S2S: ,a%$le "S2S: ,a%$le "

  • 8/17/2019 Chi-Square Presentation - Nikki

    10/34

    S2S: +hat does the $-valueS2S: +hat does the $-value%ean.%ean.

    GThe e,a#t p-value )or a nondire#tional test isthe su% o) $robabilities )or the table havin& atest statisti# &reater than or equal to the value

    o) the observed test statisti#

    High p-value: i&h $robability that test statisti#= observed test statisti# Do not reect null

    hy$othesis

    Low p-value: Lo( $robability that test statisti#= observed test statisti# !eect null

    hy$othesis

  • 8/17/2019 Chi-Square Presentation - Nikki

    11/34

    S2S: ,a%$le "S2S: ,a%$le "

    i&h $robability that

    Chi-Square statisti#= our #al#ulated #hi-square statisti#

    +e do not reject  ournull hy$othesis

  • 8/17/2019 Chi-Square Presentation - Nikki

    12/34

    S2S: ,a%$le "S2S: ,a%$le "

  • 8/17/2019 Chi-Square Presentation - Nikki

    13/34

    ,a%$le 7: Testin&,a%$le 7: Testin&

    2sso#iation2sso#iation#

    #ell#hi7 @ dis$lays ho( %u#h ea#h#ell #ontributes to the overall #hi-squared value

    no #ol @ do not dis$lay totals o)#olu%n

    no ro( @ do not dis$lay totals o)

    ro(s

    #hi sq @ dis$lay #hi square statisti#s

    HO: Jender and eye #olourare not asso#iated (ith ea#hotherHA: Jender and eye #olour are

    asso#iated (ith ea#h other

  • 8/17/2019 Chi-Square Presentation - Nikki

    14/34

    ,a%$le 7: /ore S2S,a%$le 7: /ore S2S

    ,a%$les,a%$les

  • 8/17/2019 Chi-Square Presentation - Nikki

    15/34

    ,a%$le 7: /ore S2S,a%$le 7: /ore S2S

    ,a%$les,a%$les

    97-"698-"6 @ "7@ 7

    i&h $robability that

    Chi-Square statisti# = our#al#ulated #hi-squarestatisti# 9>!75K6

    +e do not reject  our nullhy$othesis

  • 8/17/2019 Chi-Square Presentation - Nikki

    16/34

    ,a%$le 7: /ore S2S,a%$le 7: /ore S2S

    ,a%$les,a%$les

    I) there (as anasso#iation0 #an

    #he#k (hi#hintera#tions

    des#ribeasso#iation bylookin& at ho(%u#h ea#h #ell

    #ontributes to theoverall Chi-square

    value

  • 8/17/2019 Chi-Square Presentation - Nikki

    17/34

    Li%itationsLi%itations

    No #ate&ories should be less than "No %ore than "'5 o) the e,$e#ted #ate&ories

    should be less than 5

    ◦  To #orre#t )or this0 #an #olle#t lar&er sa%$les or#o%bine your data )or the s%aller e,$e#ted#ate&ories until their #o%bined value is 5 or %ore

     ates Corre#tion

    ◦ +hen there is only " de&ree o) )reedo%0 re&ular#hi-test should not be used

    ◦ 2$$ly the ates #orre#tion by subtra#tin& 5)ro% the absolute value o) ea#h #al#ulated O-ter%0 then #ontinue as usual (ith the ne(#orre#ted values

  • 8/17/2019 Chi-Square Presentation - Nikki

    18/34

    +hat do these %ean.+hat do these %ean.

  • 8/17/2019 Chi-Square Presentation - Nikki

    19/34

    Likelihood 4atio ChiLikelihood 4atio Chi

    SquareSquare

  • 8/17/2019 Chi-Square Presentation - Nikki

    20/34

    Continuity-2d*usted Chi-Continuity-2d*usted Chi-Square TestSquare Test

  • 8/17/2019 Chi-Square Presentation - Nikki

    21/34

    /antel-aens3el Chi-/antel-aens3el Chi-

    Square TestSquare TestM/ @ 9n-"6r7

    r7 is the Pearson #orrelation #oe#ient 9(hi#h

    also %easures the linear asso#iation bet(een ro(and #olu%n6

    ◦ htt$:''su$$ortsas#o%'do#u%entation'#dl'en'$ro#stat'

  • 8/17/2019 Chi-Square Presentation - Nikki

    22/34

    Phi Coe#ientPhi Coe#ient

  • 8/17/2019 Chi-Square Presentation - Nikki

    23/34

    Conti&en#y Coe#ientConti&en#y Coe#ient

  • 8/17/2019 Chi-Square Presentation - Nikki

    24/34

    Cra%erQs RCra%erQs R

  • 8/17/2019 Chi-Square Presentation - Nikki

    25/34

     ates 7 , 7 Contin&en#y ates 7 , 7 Contin&en#y

     Tables TablesHO: eart Disease is not asso#iated (ith #holesterol levelsHA: eart Disease is %ore likely in $atients (ith a hi&h

    #holesterol diet

    Cal#ulate de&rees o) )reedo%: 9#-"69r-"6 @ "" @ 1

    +e need to use the 2TS CO44CTION

    H"#$C$olester

    ol

    Lo%C$olesterol

    Total

    eart Disease "5 > 22

    ,$e#ted "77 "75

    TOTAL 2' 1( )0

    C$"*+,uareTotal

    2.2&

  • 8/17/2019 Chi-Square Presentation - Nikki

    26/34

     ates 7 , 7 Contin&en#y ates 7 , 7 Contin&en#y

     Tables TablesHO: eart Disease is not asso#iated (ith #holesterol levelsHA: eart Disease is %ore likely in $atients (ith a hi&h

    #holesterol diet H"#$C$olester

    ol

    Lo%C$olesterol

    Total

    eart Disease "5 > 22,$e#ted "7

  • 8/17/2019 Chi-Square Presentation - Nikki

    27/34

    ,a%$le ": Testin& )or,a%$le ": Testin& )orPro$ortionsPro$ortions

    ?7@5 @8!;"

  • 8/17/2019 Chi-Square Presentation - Nikki

    28/34

     ates 7 , 7 Contin&en#y ates 7 , 7 Contin&en#y

     Tables TablesHO: eart Disease is not asso#iated (ith #holesterol levelsHA: eart Disease is %ore likely in $atients (ith a hi&h

    #holesterol diet

    8!;" = ";7 ∴ +e do not reject  our null hy$othesis

    H"#$C$olester

    ol

    Lo%C$olesterol

    Total

    eart Disease "5 > 22,$e#ted "7 8>

  • 8/17/2019 Chi-Square Presentation - Nikki

    29/34

    isherQs ,a#t TestisherQs ,a#t Test

    Le)t: Use (hen the alternative to inde$enden#e isne&ative asso#iation bet(een the variables Theseobservations tend to lie in lo(er le)t and u$$erri&ht #ells o) the table S%all $-value @ Likelyne&ative asso#iation

    4i&ht: Use this one-sided test (hen the alternativeto inde$enden#e is $ositive asso#iation bet(eenthe variables These observations tend to lie inu$$er le)t and lo(er ri&ht #ells or the table S%all

    $-value @ Likely $ositive asso#iation

     T(o-Tail: Use this (hen there is no $rioralternative

  • 8/17/2019 Chi-Square Presentation - Nikki

    30/34

     ates 7 , 7 Contin&en#y ates 7 , 7 Contin&en#y

     Tables Tables

  • 8/17/2019 Chi-Square Presentation - Nikki

    31/34

     ates 7 , 7 Contin&en#y ates 7 , 7 Contin&en#y

     Tables Tables

  • 8/17/2019 Chi-Square Presentation - Nikki

    32/34

    HO: eart Disease is not

    asso#iated (ith#holesterol levels

    HA: eart Disease is

    %ore likely in $atients(ith a hi&h #holesterol

    diet

  • 8/17/2019 Chi-Square Presentation - Nikki

    33/34

    Con#lusionCon#lusion

     The Chi-square test is i%$ortant in testin&the asso#iation bet(een variables and'or#he#kin& i) oneQs e,$e#ted $ro$ortions %eetthe reality o) oneQs e,$eri%ent

     There are %ulti$le #hi-square tests0 ea#h#atered to a s$e#iE# sa%$le si3e0 de&rees o))reedo%0 and nu%ber o) #ate&ories

    +e #an use S2S to #ondu#t Chi-square testson our data by utili3in& the #o%%and procfreq

  • 8/17/2019 Chi-Square Presentation - Nikki

    34/34

    4e)eren#es4e)eren#es

    Chi-Square Test Des#ri$tions:http://www.enviroliteracy.org/pdf/materials/121.pdf 

    http://12!.12".!2.22/#iol12/$tatistics/%ppendi& '2('2'2)he'2*hi-$quare'2)+st.pdf 

    O3de%ir T and yduran 75 Co%$arison o) #hi-square and likelihood ratio #hi-square tests: $o(er o)test Vournal o) 2$$lied S#ien#es 4esear#h "976:7;7-7;;

    S2S Su$$ort (ebsite: http://www.sas.com/inde&.html

    ,+ procedure0 

     ouTube Chi-square S2S Tutorial 9user: m#ate16:http://www.youtu#e.com/watchv%*#34)q56