Re: Categorical Data Question



Richard Ulrich wrote:

--- snip ---

Then how should I test goodness of fit? Should I use chi-square or G-square?

I think you are suggesting "Pearson" versus "Likelihood" tests
on the contingency table. They are not usually the best choice.


I also took G-squared to mean the likelihood ratio chi-square. But "contingency table" suggests a chi-square test of association, whereas the OP wants a goodness of fit test, I think. Although it may not be done as often, one can compute a likelihood ratio chi-square for a goodness of fit test too.

G^2 = 2*SUM[O*ln(O/E)]

where O = observed count and E = expected count.

I've never seen anything that compares the properties of G^2 and Pearson's chi-square for goodness of fit tests. The closest thing I have is this passage from Agresti (1990) comparing them for contingency tables.

------- Beginning of excerpt -----
It is not simple to describe the sample size needed for the chi-squared distribution to approximate well the exact distributions of X^2 and G^2 [or L^2]. For a fixed number of cells, X^2 usually converges more quickly than G^2. The chi-squared approximation is usually poor for G^2 when n/IJ < 5 [where n = the grand total and IJ = rc = the number of cells in the table]. When I or J [i.e., r or c] is large, it can be decent for X^2 for n/IJ as small as 1, if the table does not contain both very small and moderately large expected frequencies. (Agresti, 1990, p. 49)
----------- End of excerpt -------

X^2 = Pearson's chi-square test statistic
G^2 = likelihood ratio chi-square test statistic (sometimes called L^2)


--
Bruce Weaver
bweaver@xxxxxxxxxxxx
www.angelfire.com/wv/bwhomedir
.



Relevant Pages

  • chi-square two sample test
    ... that data set. ... Now I want to test the goodness of fit of ... that distribution to the data(notice particularly that the ... exist a function named'chi2gof'which can do the chi-square ...
    (comp.soft-sys.matlab)
  • Re: chi-square test goodness of fit
    ... "Alexis Gatt" wrote in message ... > According to a chi-square table I found in a book, ... A 100% goodness of fit means that the curve ...
    (sci.stat.math)
  • Re: chi-square test goodness of fit
    ... "Alexis Gatt" wrote in message ... > According to a chi-square table I found in a book, ... A 100% goodness of fit means that the curve ...
    (sci.stat.edu)
  • Re: Chi-Square Question
    ... > I would be grateful of some advice please. ... and have been trying to use Chi-Square test in ... You can still compute Chi-square, though it will be hard to interpret. ... in such cells may dominate the overall ch-squared). ...
    (sci.stat.math)