EPI 221 Sep 26

## Settings for RMarkdown http://yihui.name/knitr/options#chunk_options
opts_chunk$set(comment = "", warning = FALSE, message = FALSE, tidy = FALSE, 
    echo = T, fig.width = 5, fig.height = 5)
options(width = 116, scipen = 5, digits = 5)

setwd("~/statistics/epi221/")

N Engl J Med 2000;343:1520-8 Comparison of upper gastrointestinal toxicity of rofecoxib and naproxen in patients with rheumatoid arthritis. VIGOR Study Group.

Table constructed from the numbers given in the paper. In the high risk group, MI was in 0 patients in the control and 9 patientsin the rofecoxib group.

q11 <- array(c(162,9,161,0,
               3885,8,3868,4),
             dim = c(2,2,2))

dimnames(q11) <- list(c("total number","MI cases"), c("Rofecoxib","Naproxen"), c("Highrisk group","Non-high riskgroup"))

addmargins(q11,3)
, , Highrisk group

             Rofecoxib Naproxen
total number       162      161
MI cases             9        0

, , Non-high riskgroup

             Rofecoxib Naproxen
total number      3885     3868
MI cases             8        4

, , Sum

             Rofecoxib Naproxen
total number      4047     4029
MI cases            17        4

Calculation from the numbers in the paper

From the paper,
n = 4047 for rofecoxib group,
n = 4029 for naproxen group.

“Myocardial infarctions were less common in the naproxen group than in the rofecoxib group (0.1 percent vs. 0.4 percent.”

Thus, the numbers of MIs are 16 (probably 17 in truth due to decimal precision) in the rofecoxib group, and 4 in the naproxen group.

c(rofecoxib = 4047, naproxen = 4029) * c(0.004,0.001)
rofecoxib  naproxen 
   16.188     4.029 

“Four percent of the study subjects met the criteria of the Food and Drug Administration (FDA) for the use of aspirin for secondary cardiovascular prophylaxis (presence of a history of myocardial infarction, angina, cerebrovas- cular accident, transient ischemic attack, angioplasty, or coronary bypass) but were not taking low-dose aspirin therapy.”

From the sentence above, 4 percent of the subjects were high risk. Thus, 162 in the rofecoxib group and 161 in the naproxen group were high-risk patients. Thus, 3885 in the rofecoxib group and 3868 in the naproxen group were not in the high-risk group.

## High risk
c(rofecoxib = 4047, naproxen = 4029) * 0.04
rofecoxib  naproxen 
   161.88    161.16 
## Low risk
c(rofecoxib = 4047, naproxen = 4029) * (1 - 0.04)
rofecoxib  naproxen 
   3885.1    3867.8 

“These patients accounted for 38 percent of the patients in the study who had myocardial infarctions. In the other patients the difference in the rate of myocardial infarction between groups was not significant (0.2 percent in the rofecoxib group and 0.1 percent in the naproxen group).”

From the sentence above, 0.2% in the non-high-risk rofecoxib group and 0.1% in the non-high-risk naproxen group had MI, thus, 8 and 4 had MI, respectively.

c(rofecoxib = 4047, naproxen = 4029) * (1 - 0.04) * c(0.002, 0.001)
rofecoxib  naproxen 
   7.7702    3.8678 

By subtraction from the overall numbers (17 and 4), the numbers of MI in the high-risk group are 9 in the rofecoxib group and 0 in the naproxen group.

c(rofecoxib = 17, naproxen = 4) - c(8,4)
rofecoxib  naproxen 
        9         0