R/Pearson_LR_homogeneity_test_stratified_2x2.R
Pearson_LR_homogeneity_test_stratified_2x2.Rd
The Pearson chi-squared and likelihood ratio tests for homogeneity over strata
Described in Chapter 10 "Stratified 2x2 Tables and Meta-Analysis"
Pearson_LR_homogeneity_test_stratified_2x2(n, link = "logit")
An object of the contingencytables_result class,
basically a subclass of base::list()
. Use the utils::str()
function
to see the specific elements returned.
# Smoking and lung cancer (Doll and Hill, 1950)
Pearson_LR_homogeneity_test_stratified_2x2(doll_hill_1950)
#> The likelihood ratio test: P = 0.01661, T0 = 5.737 (df = 1)
#> The Pearson chi-squared test: P = 0.02471, T0 = 5.044 (df = 1)
# Prophylactice use of Lidocaine in myocardial infarction (Hine et al., 1989)
Pearson_LR_homogeneity_test_stratified_2x2(hine_1989)
#> The likelihood ratio test: P = 0.90840, T0 = 1.540 (df = 5)
#> The Pearson chi-squared test: P = 0.90876, T0 = 1.537 (df = 5)