Home  >>  Archives  >>  Volume 8 Number 2  >>  st0142

The Stata Journal
Volume 8 Number 2: pp. 147-169



Subscribe to the Stata Journal
cover

Multinomial goodness–of–fit: Large–sample tests with survey design correction and exact tests for small samples

Ben Jann
ETH Zürich
Zürich, Switzerland
[email protected]
Abstract.   I introduce the new mgof command to compute distributional tests for discrete (categorical, multinomial) variables. The command supports largesample tests for complex survey designs and exact tests for small samples as well as classic large-sample x2-approximation tests based on Pearson’s X2, the likelihood ratio, or any other statistic from the power-divergence family (Cressie and Read, 1984, Journal of the Royal Statistical Society, Series B (Methodological) 46: 440–464). The complex survey correction is based on the approach by Rao and Scott (1981, Journal of the American Statistical Association 76: 221–230) and parallels the survey design correction used for independence tests in svy: tabulate. mgof computes the exact tests by using Monte Carlo methods or exhaustive enumeration. mgof also provides an exact one-sample Kolmogorov–Smirnov test for discrete data.
Terms of use     View this article (PDF)

View all articles by this author: Ben Jann

View all articles with these keywords: mgof, mgofi, multinomial, goodness-of-fit, chi-squared, categorical data, exact tests, Monte Carlo, exhaustive enumeration, combinatorial algorithms, complex survey correction, power-divergence statistic, Kolmogorov–Smirnov, Benford's law

Download citation: BibTeX  RIS

Download citation and abstract: BibTeX  RIS