[R] In chisq.test(x) : Chi-squared approximation may be incorrect

Marc Schwartz marc_schwartz at comcast.net
Wed Jan 16 04:46:17 CET 2008


I would also review:

Chi-squared and Fisher-Irwin tests of two-by-two tables with small
sample recommendations
Ian Campbell
Stat in Med 26:3661-3675; 2007
http://www3.interscience.wiley.com/cgi-bin/abstract/114125487/ABSTRACT

and the bottom Frank Harrell's page here:

http://biostat.mc.vanderbilt.edu/twiki/bin/view/Main/DataAnalysisDisc

where he has some comments on the above.

HTH,

Marc Schwartz

Simon Blomberg wrote:
> Why do people automatically jump to Fisher's Exact test? That test
> conditions on BOTH marginal row totals. Usual contingency table analyses
> condition on one margin, at most. You should look very carefully at the
> underlying model for your data. Fisher's Exact test might not be
> appropriate. Agresti's "Categorical Data Analysis" has a good discussion
> of this.
>
> Simon.
>
> On Tue, 2008-01-15 at 21:49 -0500, My Coyne wrote:
>> Thank you for your help; I will try fisher.test().
>>
>>
>>
>>
>>
>> From: anna freni sterrantino [mailto:annafreni at yahoo.it]
>> Sent: Tuesday, January 15, 2008 8:53 PM
>> To: mcoyne at boninc.com; r-help at stat.math.ethz.ch
>> Subject: Re: [R] In chisq.test(x) : Chi-squared approximation may be incorrect
>>
>>
>>
>> Hi!
>>   the warning you got
>> "Chi-squared approximation may be incorrect"
>> is because probably there are less than 5 observations in
>> the cell. Maybe will help to
>> try fisher.test()
>>
>> Cheers
>>
>> Anna
>>
>>
>>
>>
>>
>>
>>
>>
>> ----- Messaggio originale -----
>> Da: My Coyne<mcoyne at boninc.com>
>> A: r-help at stat.math.ethz.ch
>> Inviato: Lunedì 14 gennaio 2008, 21:51:30
>> Oggetto: [R] In chisq.test(x) : Chi-squared approximation may be incorrect
>>
>> Hello,
>>
>>
>>
>> I received the following warning when running chi-square;
>>
>> n  Is there a way to catch the 'error' code of 'warning' after run
>> chisq.test(x)?
>>
>> n  What does this error mean?
>>
>>
>>
>> Thank you for your help.
>>




More information about the R-help mailing list