• Nenhum resultado encontrado

SMALL-SAMPLE CONFIDENCE INTERVALS FOR 2 = 2 TABLES*

No documento Categorical Data Analysis (páginas 113-116)

INFERENCE FOR CONTINGENCY TABLES

98

TABLE 3.9 Example for Exact Conditional Test Smoking Level Žcigarettesrday.

0 124 )25

Control 25 25 12

Myocardial infarction 0 1 3

Source: Reprinted with permission, based on Table 5 in

Ž .

S. Shapiro et al., Lancet743746 1979 .

of tables with the given margins that are no more likely to occur than the table observed. Other exact tests order the tables using a statistic describing

Ž . 2

distance from H0. Yates 1934 used X . The P-value is then the null value

Ž 2 2. 2

of P X GXo for observed value Xo. When classifications have ordered categories, an ordinal statistic is more relevant. For the alternative hypothesis

Ž .

of a positive association, we could use P TGto , whereT is the correlation or gamma and where to denotes its observed value.

We illustrate an exact test for ordered categories with Table 3.9, which cross-classifies level of smoking and myocardial infarction for a sample of young women in a case᎐control study. The second row contains small counts, and large-sample tests may be inappropriate. Given the marginal counts, the only table having greater evidence of positive association between smoking

Ž . Ž .

and myocardial infarction has counts 25,26,11 for row 1 and 0,0,4 in row 2.

Conditional on both sets of margins, the null probability of the observed

w Ž .x

table and this more extreme table based on formula 3.19 equals 0.018.

Although the sample contains only four myocardial infarction patients, evi-dence exists of a positive association. The evievi-dence is stronger than using

2 Ž 2 2.

X , which ignores the ordering of categories. The exact P X GXo s

Ž 2 .

P X G6.96 s0.052.

Special algorithms and software for computing exact tests for I= J tables

Ž .

are widely available e.g., Mehta and Patel 1983; see also Appendix A . We recommend these tests when asymptotic approximations may be invalid.

Computing time increases exponentially as n, I, or J increase. However, one can use Monte Carlo to sample randomly from the set of tables with the given margins. The estimated P-value is then the sample proportion of tables having test statistic value at least as large as the value observed.

As Iandror J increase, the number of possible values for any test statistic T tends to increase. Thus, the conservativeness issue for conditional tests becomes less problematic.

SMALL-SAMPLE CONFIDENCE INTERVALS FOR 2=2 TABLES 99 distributions are the basis of confidence intervals for measures such as the odds ratio.

3.6.1 Small-Sample Inference for the Odds Ratio

4

For multinomial sampling, the distribution of ni j depends on n and cell

4

probabilities ␲i j . For 2=2 tables, the odds ratio is

␲ ␲11 2211Ž1y␲1qy␲q1q␲11.

␪s s .

␲ ␲12 21 Ž␲1qy␲11. Ž␲q1y␲11.

4

Hence,␲11 is a function of ␪ and ␲1q,␲q1 . The same argument applies to

4

any ␲i j, so the multinomial distribution of ni j can use parameters ␪,␲1q,␲q14. Conditional on n1q,nq14, the distribution of ni j4 depends only on ␪. Since n11 determines all other cell counts, given the marginal

4

totals, the conditional distribution of ni j is specified by some function

Ž . Ž . Ž .

P n11st sf t;n1q,nq1,n,␪ . This distribution Fisher 1935c is the non-central hypergeometric,

nyn n1q 1qt

ž

t

/ ž

nq1yt

/

f tŽ ;n1q,nq1,n,␪.s usm

Ý

mqy

ž

n1uq

/ ž

nnq1yyn1qu

/

u Ž3.20.

for myFtFmq.

A confidence interval for␪ results from inverting the test of H0: ␪s␪0, having observed n11sto. For Ha: ␪)␪0, the P-value is

Ps

Ý

f tŽ ;n1q,nq1,n,␪0..

tGto

For testing against H0: ␪-␪0,

Ps

Ý

f tŽ ;n1q,nq1,n,␪0..

tFto

Ž .

When ␪0s1, these are one-sided Fisher’s exact tests. Cornfield 1956 constructed a confidence interval using the tail method. The lower endpoint is␪0 for which Ps␣r2 in testing against Ha:␪)␪0. The upper endpoint is

0 for which Ps␣r2 for Ha:␪-␪0. The interval is the set of ␪0 for which both one-sided P-values G␣r2.

As in Fisher’s exact test, the conditional approach to interval estimation is necessarily conservative because of discreteness. The actual confidence coef-ficient, defined as the infimum of the coverage probabilities for all possible

␪, has the nominal confidence level as a lower bound. Less conservative

INFERENCE FOR CONTINGENCY TABLES

100

behavior and shorter intervals result from inverting a single two-sided test rather than inverting two one-sided tests Agresti and Min 2001; Baptista andŽ Pike 1977 . An alternative approach with independent binomial samples. inverts nonnull unconditional small-sample tests. Because of the reduced discreteness, such intervals are also usually shorter.

The conditional ML estimate of ␪ is the value of ␪ that maximizes

Ž .

probability 3.20 . Differentiating the log likelihood with respect to␪ shows

Ž .

that this estimate satisfies the equation n11sE n11 in␪, where the expecta-ˆ

Ž .

tion refers to distribution 3.20 . This equation has a unique solution␪and is

Ž .

solved using iterative methods Cornfield 1956 . This estimator differs from the unconditional ML estimator␪ˆsn n11 22rn n12 21, which uses the ML

4 4

mates of ␲i j for the multinomial distribution of ni j. Using statistical software, we can calculate conditional ML estimates and small-sample

confi-Ž .

dence intervals for odds ratios e.g., for SAS, see Table A.2 . 3.6.2 Tea Tasting Example

We illustrate with Table 3.8 from Fisher’s tea-tasting experiment. The condi-tional ML estimate of ␪ is 6.4. Software provides the Cornfield tail-method

Ž .

interval 0.2, 626.2 with confidence coefficient guaranteed G0.95. Not surprisingly, it is very wide because of the small sample. Inverting a family of two-sided ‘‘exact’’ conditional score tests gives a more precise interval, 0.3,Ž 306.2 . The unconditional approach is not appropriate here because of the. sampling design. If the table were two binomial samples, that approach givesw

Ž . x

interval 0.4, 234.4 by inverting ‘‘exact’’ unconditional score tests.

3.6.3 Impact of Discreteness on Exact Confidence Intervals

Small-sample inference is ‘‘exact’’ in the sense that the conditional distribu-tion is free of nuisance parameters. Confidence intervals and tests use exact probability calculations rather than approximate ones. However, their operat-ing characteristics are conservative because of discreteness.

Large-sample methods do not have the guarantee of bounds on error probabilities. They can be conservative or liberal, and thus their results can appear quite different from exact methods. For example, for the tea-tasting

Ž .

data Table 3.8 , the P-value for the Pearson chi-squared test equals 0.157, compared to 0.486 for the two-sided exact test. The 95% large-sample

Ž . Ž .

confidence interval 3.2 for the odds ratio is 0.4, 220.9 , compared to

Ž .

Cornfield’s exact interval of 0.2, 626.2 . Normally, one would prefer an exact method over an approximate one. When the conditional distribution is highly discrete, however, the choice is not so obvious. Exact methods then can be quite conservative, especially with small samples.

For highly discrete data, it seems sensible to use adjustments of exact methods based on the mid-P-value. Confidence intervals with the conditional approach then invert hypergeometric tests of ␪s␪0 using the mid-P-value.

Although not guaranteed to have error probabilities no greater than the

EXTENSIONS FOR MULTIWAY TABLES AND NONTABULATED RESPONSES 101 nominal level, this method usually comes closer than the exact method to the desired level. Compared to large-sample methods, it has the advantage of working well as the degree of discreteness diminishes, since it then is essentially the same as the corresponding exact method using an ordinary P-value.

Inference based on the mid-P-value compromises between the conserva-tiveness of exact methods and the uncertain adequacy of large-sample meth-ods. For interval estimation of the odds ratio, this method tends to be a bit conservative, but for small samples can yield much shorter intervals than the Cornfield exact interval. For the tea-tasting data, for instance, the 95%

confidence interval based on inverting two one-sided hypergeometric tests

Ž .

using the mid-P-value is 0.31, 309 , compared to the Cornfield interval of Ž0.21, 626 ..

3.6.4 Small-Sample Inference for Difference of Proportions

The conditional approach to eliminating nuisance parameters works when

Ž .

those parameters have sufficient statistics. However, we’ll see Section 6.7.9 that reduced sufficient statistics occur only for certain models. For binary data, such models must have odds ratios as parameters. For 2=2 tables, the conditional approach cannot yield confidence intervals for differences or ratios of proportions. The unconditional approach is more complex but does not require sufficient statistics. We used it in Section 3.5.5 for testing

1y␲2s0 with independent binomial samples.

A small-sample confidence interval inverts the corresponding uncondi-tional test of H0:␲1y␲2s␦0, for any fixedy1-␦0-1. The probability

Ž . Ž .

function for the table is the product of bin n1,␲1 and bin n2,␲2 mass functions. One can express this in terms of ␦s␲1y␲2 and a nuisance

Ž .

parameter␭. For instance, if ␭s␲1q␲2, one substitutes␲1s ␭q␦ r2

Ž .

and␲2s ␭y␦ r2. For␦s␦0 and a fixed value of ␭, one then uses this binomial product to calculate the probability that the test statistic is at least as large as observed. The P-value is the supremum of such probabilities calculated over all possible values for␭. This provides a family of tests for the various values of ␦0. The confidence interval for␲1y␲2 is the set of ␦0 for which this P-value exceeds ␣.

This approach can be quite conservative. For details regarding various test

Ž . Ž .

statistics, see Agresti and Min 2001 , Coe and Tamhane 1993 , Santner and

Ž . Ž .

Snell 1980 , and Santner and Yamagami 1993 . It is better to invert a single

Ž .

two-sided test, as in Coe and Tamhane 1993 , than to invert two separate one-sided tests.

3.7 EXTENSIONS FOR MULTIWAY TABLES AND

No documento Categorical Data Analysis (páginas 113-116)