chi-square test

Post on 04-Jan-2016

20 Views

Category:

Documents

1 Downloads

Preview:

Click to see full reader

DESCRIPTION

Chi-Square test. PRESENTED BY: Dr.Zhian Salah Ramzi Head of community and Family medicine/ sulaimani university. Chi-Square Test. Evaluates whether observed frequencies for a qualitative variable (or variables) are adequately described by hypothesized or expected frequencies. - PowerPoint PPT Presentation

TRANSCRIPT

Chi-Square test

PRESENTED BYPRESENTED BY::

Dr.Zhian Salah RamziDr.Zhian Salah Ramzi

Head of community andHead of community andFamily medicine/ sulaimani universityFamily medicine/ sulaimani university

Chi-Square TestChi-Square Test

Evaluates whether observed Evaluates whether observed frequencies for a qualitative frequencies for a qualitative variable (or variables) are variable (or variables) are adequately described by adequately described by hypothesized or expected hypothesized or expected frequencies.frequencies.

Qualitative (or categorical) data is Qualitative (or categorical) data is a set of observations where any a set of observations where any single observation is a word or code single observation is a word or code that represents a class or category.that represents a class or category.

Nonparametric StatisticsNonparametric Statistics

Chi-Square (Chi-Square (22 )Test )Test Used to analyze data in situations where one wishes Used to analyze data in situations where one wishes

to test whether the observed number of responses in to test whether the observed number of responses in a category differs from the expected number that a category differs from the expected number that fall in that category.fall in that category.

Dependent Variable is nominal.Dependent Variable is nominal. HHoo represents the expected proportion of responses represents the expected proportion of responses

falling in a given category.falling in a given category.

• Where k = # of categories, Oi = observed number of cases in each category, Ei = expected number of cases in each category.

• When Ho is true, Oi Ei and 2 will be small. If Ho is false,

then Oi Ei and 2 will be large.

Simple and complex – one variable or multiple variables

k

Ei

EiOi 22 )(

Recent studies have found that most teens are knowledgeable about AIDS, yet many continue to practice high-risk sexual behaviors. King and Anderson (1993) asked young people the following question: “If you could have sexual relations with any and all partners of your choosing, as often as you wished, for the next 2 (or 10) years, but at the end of that time period you would die of AIDS, would you make this choice?” A five-point Likert scale was used to assess the subjects’ responses. For the following

data, the responses “probably no,” “unsure,” “probably yes”, and “definitely yes” were pooled into the category “other.” Using the .05 level of significance, test for independence.

Definitely No Definitely No OtherOther

MalesMales 451451 165165

FemalesFemales 509509 118118

Chi-Square Test for Chi-Square Test for IndependenceIndependence

State the research hypothesis.State the research hypothesis. Is willingness to participate in Is willingness to participate in

unprotected sex independent of unprotected sex independent of gender?gender?

State the statistical hypothesis.State the statistical hypothesis.

HH0:0: Response to the question and gender are not relatedResponse to the question and gender are not relatedResponse to the question and gender are relatedResponse to the question and gender are relatedHHA:A:

Chi-Square Test for Chi-Square Test for IndependenceIndependence

To find expected values:To find expected values: Find column, row, and overall totals.Find column, row, and overall totals.

Definitely NoDefinitely No OtherOtherTotalTotal

MalesMales 451451 165165 616616

FemalesFemales 509509 118118 627627

TotalTotal 960960 283283 12431243

Chi-Square Test for Chi-Square Test for IndependenceIndependence

To find expected values:

Definitely NoDefinitely No OtherOtherTotalTotal

MalesMales 451 (475.75) 165 616

FemalesFemales 509509 118118 627627

TotalTotal 960960 283283 12431243

EiEi

EiEi

EiEi

Chi-Square Test for Chi-Square Test for IndependenceIndependence

To find expected values:

Definitely No OtherTotal

Males 451 (475.75) 165 616

Females 509 (484.25) 118 627

Total 960 283 1243

EiEi

EiEi

Chi-Square Test for Chi-Square Test for IndependenceIndependence

To find expected values:

Definitely No OtherTotal

Males 451 (475.75) 165 (140.25)616

Females 509 (484.25) 118 627

Total 960 283 1243

EiEi

EiEi

Chi-Square Test for Chi-Square Test for IndependenceIndependence

To find expected values:

Definitely No OtherTotal

Males 451 (475.75) 165 (140.25)616

Females 509 (484.25) 118 (142.75)627

Total 960 283 1243

EiEi

EiEi

Chi-Square Test for Chi-Square Test for IndependenceIndependence

Set the decision rule. Degrees of Freedom

(number of columns - 1) (number of rows -1) (c-1)(r-1)

1)1)(1()12)(12( dfDefinitely No

Other

Males 451 165

Females 509 118

Chi-Square Chi-Square

Set the decision rule.

84.3

1

05.

2

crit

df

Chi-Square Test for Chi-Square Test for IndependenceIndependence

Calculate the test statistic.Definitely No Other

Total

Males 451 (475.75) 165 (140.25)616

Females 509 (484.25) 118 (142.75)627

Total 960 283 124375.142

)75.142118(

25.140

)25.140165(

25.484

)25.484509(

75.475

)75.475451( 22222

75.142

56.612

25.140

56.612

25.484

56.612

75.475

56.612

21.11

29.437.426.129.1

k

Ei

EiOi 22 )(

The Chi-Square testThe Chi-Square test

Chi-Square Test for Chi-Square Test for IndependenceIndependence

Decide if your result is significant. Reject H0, 11.21>3.84

Interpret your results. Willingness to engage in unprotected sex

and gender are not independent.Definitely No Other

Total

Males 451 (475.75) 165 (140.25)616

Females 509 (484.25) 118 (142.75)627

Total 960 283 1243

top related