Вы находитесь на странице: 1из 6

The Chi Square Statistic

Types of Data:

There are basically two types of random variables and they yield two types of data:
numerical and categorical. A chi square (X ) statistic is used to investigate whether
2

distributions of categorical variables differ from one another. Basically categorical


variable yield data in the categories and numerical variables yield data in numerical
form. Responses to such questions as "What is your major?" or Do you own a car?"
are categorical because they yield data such as "biology" or "no." In contrast,
responses to such questions as "How tall are you?" or "What is your G.P.A.?" are
numerical. Numerical data can be either discrete or continuous. The table below may
help you see the differences between these two variables.

Possible
Data Type Question Type
Responses
Categorical What is your sex? male or female
Disrete- How many cars do you
Numerical two or three
own?
Numerical Continuous - How tall are you? 72 inches

Notice that discrete data arise fom a counting process, while continuous data arise
from a measuring process.

The Chi Square statistic compares the tallies or counts of categorical responses
between two (or more) independent groups. (note: Chi square tests can only be used
on actual numbers and not on percentages, proportions, means, etc.)

2 x 2 Contingency Table

There are several types of chi square tests depending on the way the data was
collected and the hypothesis being tested. We'll begin with the simplest case: a 2 x 2
contingency table. If we set the 2 x 2 table to the general notation shown below in
Table 1, using the letters a, b, c, and d to denote the contents of the cells, then we
would have the following table:

Table 1. General notation for a 2 x 2 contingency table.


Variable 1
Variable 2 Data type 1 Data type 2 Totals
Category 1 a b a+b
Category 2 c d c+d
Total a+c b+d a+b+c+d=N

For a 2 x 2 contingency table the Chi Square statistic is calculated by the formula:

Note: notice that the four components of the denominator are the four totals from the
table columns and rows.

Suppose you conducted a drug trial on a group of animals and you hypothesized that
the animals receiving the drug would show increased heart rates compared to those
that did not receive the drug. You conduct the study and collect the following data:

Ho: The proportion of animals whose heart rate increased is independent of drug
treatment.

Ha: The proportion of animals whose heart rate increased is associated with drug
treatment.

Table 2. Hypothetical drug trial results.


Heart Rate No Heart Rate
Total
Increased Increase
Treated 36 14 50
Not treated 30 25 55
Total 66 39 105

Applying the formula above we get:

Chi square = 105[(36)(25) - (14)(30)] / (50)(55)(39)(66) = 3.418


2

Before we can proceed we eed to know how many degrees of freedom we have. When
a comparison is made between one sample and another, a simple rule is that the
degrees of freedom equal (number of columns minus one) x (number of rows minus
one) not counting the totals for rows or columns. For our data this gives (2-1) x (2-1)
= 1.
We now have our chi square statistic (x2 = 3.418), our predetermined alpha level of
significance (0.05), and our degrees of freedom (df = 1). Entering the Chi square
distribution table with 1 degree of freedom and reading along the row we find our
value of x2 (3.418) lies between 2.706 and 3.841. The corresponding probability is
between the 0.10 and 0.05 probability levels. That means that the p-value is above
0.05 (it is actually 0.065). Since a p-value of 0.65 is greater than the conventionally
accepted significance level of 0.05 (i.e. p > 0.05) we fail to reject the null hypothesis.
In other words, there is no statistically significant difference in the proportion of
animals whose heart rate increased.

What would happen if the number of control animals whose heart rate increased
dropped to 29 instead of 30 and, consequently, the number of controls whose hear rate
did not increase changed from 25 to 26? Try it. Notice that the new x2 value is 4.125
and this value exceeds the table value of 3.841 (at 1 degree of freedom and an alpha
level of 0.05). This means that p < 0.05 (it is now0.04) and we reject the null
hypothesis in favor of the alternative hypothesis - the heart rate of animals is different
between the treatment groups. When p < 0.05 we generally refer to this as a
significant difference.

Chi Square Test of Independence

For a contingency table that has r rows and c columns, the chi square test can be
thought of as a test of independence. In a test ofindependence the null and alternative
hypotheses are:

Ho: The two categorical variables are independent.

Ha: The two categorical variables are related.

We can use the equation Chi Square = the sum of all the(fo - fe) / fe
2

Here fo denotes the frequency of the observed data and fe is the frequency of the
expected values. The general table would look something like the one below:

1. Wuensch, Karl L. (October 4, 2005). "What is a Likert Scale? and How Do You
Pronounce 'Likert?'". East Carolina University. Retrieved April 30, 2009.
2. Jump up^ Likert, Rensis (1932). "A Technique for the Measurement of
Attitudes". Archives of Psychology. 140: 155.
3. Jump up^ Carifio, James and Rocco J. Perla. (2007) "Ten Common
Misunderstandings, Misconceptions, Persistent Myths and Urban Legends about
Likert Scales and Likert Response Formats and their Antidotes." Journal of
Social Sciences 3 (3): 106-116
4. Jump up^ Burns, Alvin; Burns, Ronald (2008). Basic Marketing
Research (Second ed.). New Jersey: Pearson Education. p. 245. ISBN 978-0-
13-205958-9.
5. Jump up^ A. van Alphen, R. Halfens, A. Hasman and T. Imbos. (1994). Likert or
Rasch? Nothing is more applicable than good theory. Journal of Advanced
Nursing. 20, 196-201
6. Jump up^ Burns, Alvin; Burns, Ronald (2008). Basic Marketing
Research (Second ed.). New Jersey: Pearson Education. p. 250. ISBN 978-0-
13-205958-9.
7. Jump up^ Dawes, John (2008). "Do Data Characteristics Change According to
the number of scale points used? An experiment using 5-point, 7-point and 10-
point scales".International Journal of Market Research. 50 (1): 6177.
8. Jump up^ Allen, Elaine and Seaman, Christopher (2007). "Likert Scales and
Data Analyses". Quality Progress. pp. 6465.
9. Jump up^ Armstrong, Robert (1987). "The midpoint on a Five-Point Likert-Type
Scale". Perceptual and Motor Skills. 64 (2): 359
362. doi:10.2466/pms.1987.64.2.359.
10. Jump up^ Jamieson, Susan (2004). Likert Scales: How to (Ab)use Them,
Medical Education, Vol. 38(12), pp.1217-1218
11. Jump up^ Norman, Geoff (2010). Likert scales, levels of measurement and the
laws of statistics. Advances in Health Science Education. Vol 15(5) pp625-632
12. Jump up^ Carifio and Perla, 2007, Ten Common Misunderstandings,
Misconceptions, Persistent Myths and Urban Legends about Likert Scales and
Likert Response Formats and their Antidotes. Journal of Social Sciences 3 (3):
106-116.
13. Jump up^ Norman, Geoff (2010)
14. Jump up^ Mogey, Nora (March 25, 1999). "So You Want to Use a Likert
Scale?". Learning Technology Dissemination Initiative. Heriot-Watt University.
Retrieved April 30, 2009.
15. Jump up^ B Robbins, Naomi; M Heiberger, Richard (2011). "Plotting Likert and
Other Rating Scales". JSM 2011: 10581066.
16. Jump up^ Reips, Ulf-Dietrich; Funke, Frederik (2008). "Interval level
measurement with visual analogue scales in Internet-based research: VAS
Generator". Behavior Research Methods. 40(3): 699
704. doi:10.3758/BRM.40.3.699.PMID 18697664.
17. Jump up^ Johanson, George A.; Gips, Crystal J. (1993). "Paired Comparison
Intransitivity: Useful Information or Nuisance?" (PDF). Paper presented at the
Annual Meeting of the American Educational Research Association (Atlanta, GA,
April 1216, 1993).
18. Jump up^ Labovitz, S (1967). "Some observations on measurement and
statistics". Social Forces. 46: 151160.doi:10.2307/2574595.
19. Jump up^ Traylor, Mark (October 1983). "Ordinal and interval scaling". Journal
of the Market Research Society. 25 (4): 297303.
20. Jump up^ Babbie, Earl R. (2005). The Basics of Social Research. Belmont, CA:
Thomson Wadsworth. p. 174. ISBN 0-534-63036-7.
21. Jump up^ Meyers, Lawrence S.; Anthony Guarino; Glenn Gamst
(2005). Applied Multivariate Research: Design and Interpretation. Sage
Publications. p. 20. ISBN 1-4129-0412-9.
22. Jump up^ Latham, Gary P. (2006). Work Motivation: History, Theory, Research,
And Practice. Thousand Oaks, Calif.: Sage Publications. p. 15. ISBN 0-7619-
2018-8.
Cochran's Q test
In statistics, in the analysis of two-way randomized block designs where the response variable can
take only two possible outcomes (coded as 0 and 1), Cochran's Q test is a non-
parametric statistical test to verify whether k treatments have identical effects.[1][2][3] It is named
for William Gemmell Cochran. Cochran's Q test should not be confused with Cochran's C test, which
is a variance outlier test. Put in less technical terms, requires that there only be a binary response
(success/failure or 1/0) and that there be 2 or more matched groups (groups of the same size). The
test assesses whether the proportion of successes is the same between groups. Often used to
assess if different observers of the same phenomenon have consistent results amongst themselves
(interobserver variability).

Background

Cochran's Q test assumes that there are k > 2 experimental treatments and that the observations
are arranged in b blocks; that is,

McNemar's test
In statistics, McNemar's test is a statistical test used on paired nominal data. It is applied to
2 2 contingency tables with adichotomous trait, with matched pairs of subjects, to determine
whether the row and column marginal frequencies are equal (that is, whether there is "marginal
homogeneity"). It is named after Quinn McNemar, who introduced it in 1947.[1] An application of the
test in genetics is the transmission disequilibrium test for detecting linkage disequilibrium.[2]

Definition

The test is applied to a 2 2 contingency table, which tabulates the outcomes of two tests on a
sample of n subjects, as follows.

http://www.socscistatistics.com/tests/chisquare/

http://www.socscistatistics.com/tests/chisquare2/Default2.aspx

Вам также может понравиться