A test (typically of distribution, independence, or goodness of fit), for the family of distributions use [chi-squared-distribution].
Questions tagged [chi-squared-test]
2348 questions
91
votes
2 answers
Given the power of computers these days, is there ever a reason to do a chi-squared test rather than Fisher's exact test?
Given that software can do the Fisher's exact test calculation so easily nowadays, is there any circumstance where, theoretically or practically, the chi-squared test is actually preferable to Fisher's exact test?
Advantages of the Fisher's exact…

pmgjones
- 5,543
- 8
- 36
- 36
60
votes
2 answers
What is the relationship between a chi squared test and test of equal proportions?
Suppose that I have three populations with four, mutually exclusive characteristics. I take random samples from each population and construct a crosstab or frequency table for the characteristics that I am measuring. Am I correct in saying…

hgcrpd
- 1,307
- 2
- 11
- 13
60
votes
7 answers
Is chi-squared always a one-sided test?
A published article (pdf) contains these 2 sentences:
Moreover, misreporting may be caused by the application of incorrect rules or by a lack of knowledge of the statistical test. For example, the total df in an ANOVA may be taken to be the error…

Joel W.
- 3,096
- 3
- 31
- 45
58
votes
6 answers
Warning in R - Chi-squared approximation may be incorrect
I have data showing fire fighter entrance exam results. I am testing the hypothesis that exam results and ethnicity are not mutually independent. To test this, I ran a Pearson chi-square test in R. The results show what I expected, but it gave a…

ferrelwill
- 683
- 1
- 5
- 5
56
votes
2 answers
A/B tests: z-test vs t-test vs chi square vs fisher exact test
I'm trying to understand the reasoning by choosing a specific test approach when dealing with a simple A/B test - (i.e. two variations/groups with a binary respone (converted or not). As an example I will be using the data below
Version Visits …

L Xandor
- 1,119
- 2
- 9
- 13
37
votes
4 answers
What is the difference between McNemar's test and the chi-squared test, and how do you know when to use each?
I have tried reading up on different sources, but I am still not clear what test would be the appropriate in my case. There are three different questions I am asking about my dataset:
The subjects are tested for infections from X at different…

Anto
- 693
- 1
- 8
- 13
37
votes
3 answers
Why is a likelihood-ratio test distributed chi-squared?
Why is the test statistic of a likelihood ratio test distributed chi-squared?
$2(\ln \text{ L}_{\rm alt\ model} - \ln \text{ L}_{\rm null\ model} ) \sim \chi^{2}_{df_{\rm alt}-df_{\rm null}}$

Dr. Beeblebrox
- 1,120
- 1
- 11
- 16
29
votes
6 answers
How can I test the fairness of a d20?
How can I test the fairness of a twenty sided die (d20)? Obviously I would be comparing the distribution of values against a uniform distribution. I vaguely remember using a Chi-square test in college. How can I apply this to see if a die is…

C. Ross
- 645
- 1
- 7
- 11
26
votes
3 answers
How to calculate the p-value of parameters for ARIMA model in R?
When doing time series research in R, I found that arima provides only the coefficient values and their standard errors of fitted model. However, I also want to get the p-value of the coefficients.
I did not find any function that provides the…

Lisa
- 363
- 1
- 3
- 4
24
votes
4 answers
Is this an appropriate method to test for seasonal effects in suicide count data?
I have 17 years (1995 to 2011) of death certificate data related to suicide deaths for a state in the U.S. There is a lot of mythology out there about suicides and the months/seasons, much of it contradictory, and of the literature I've reviewed, I…

svannoy
- 343
- 2
- 7
21
votes
1 answer
How exactly does Chi-square feature selection work?
I know that for each feature-class pair, the value of the chi-square statistic is computed and compared against a threshold.
I am a little confused though. If there are $m$ features and $k$ classes, how does one build the contingency table? How…

user721975
- 825
- 2
- 9
- 15
21
votes
4 answers
Comparing two histograms using Chi-Square distance
I want to compare two images of faces. I calculated their LBP-histograms. So now I need to compare these two histograms and get something that will tell how much these histograms are equal (0 - 100%).
There are many ways of solving this task, but…

Anton Holovin
- 313
- 1
- 2
- 6
19
votes
1 answer
How do I find values not given in (interpolate in) statistical tables?
Often people use programs to obtain p-values, but sometimes - for whatever reason - it may be necessary to obtain a critical value from a set of tables.
Given a statistical table with a limited number of significance levels, and a limited number of…

Glen_b
- 257,508
- 32
- 553
- 939
19
votes
2 answers
Pearson's residuals
A beginner's question about the Pearson's residual within the context of the chi-square test for goodness of fit:
As well as the test statistic, R's chisq.test function reports the Pearson's residual:
(obs - exp) / sqrt(exp)
I understand why…

Iain Dillingham
- 335
- 1
- 2
- 4
19
votes
1 answer
At What Level is a $\chi^2$ test Mathematically Identical to a $z$-test of Proportions?
BACKGROUND: Skip safely - it's here for reference, and to legitimize the question.
The opening of this paper reads:
"Karl Pearson’s famous chi-square contingency test is derived from another statistic, called the z statistic, based on the Normal…

Antoni Parellada
- 23,430
- 15
- 100
- 197