# strength.test: Strength Test for Association in Multiple Contingency Tables In DiffXTables: Pattern Analysis Across Contingency Tables

## Description

The test determines the total strength of association in multiple contingency tables.

## Usage

 `1` ``` strength.test(tables) ```

## Arguments

 `tables` a list of at least two non-negative matrices or data frames representing contingency tables.

## Details

The strength test determines total amount of association in multiple input contingency tables. Its test statistic asymptotically follows the chi-squared distribution under the null hypothesis of each table having independent row and column variables \insertCitesharma2020COPTYPDiffXTables.

The test statistic is minimized to zero if and only if row and column variables are empirically independent of each other in every table.

This test is considered a zeroth-order test in the function `type.analysis` that characterizes the difference across multiple contingency tables.

## Value

A list with class "`htest`" containing the following components:

 `statistic` the strength test statistic. `parameter` the degrees of freedom of null chi-squared distribution. `p.value` the p-value for the test, computed using the null chi-squared distribution.

## Author(s)

Ruby Sharma and Joe Song

\insertAllCited

## See Also

A second-order different test `sharma.song.test`. A first-order difference test `marginal.change.test`. The comparative type of differences across contingency tables `type.analysis`.

## Examples

 ``` 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32``` ``` # Both tables have strong association: tables <- list( matrix(c(30,0,0, 0,10,0, 0,0,20), nrow=3), matrix(c(10,0,0, 0,20,0, 0,0,30), nrow=3) ) strength.test(tables) # One table has strong association: tables <- list( matrix(c(4,0,0, 0,4,0, 0,0,4), nrow=3), matrix(c(4,0,4, 8,4,8, 4,0,4), nrow=3) ) strength.test(tables) # Both tables has no association: tables <- list( matrix(c(4,0,4, 8,4,8, 4,0,4), nrow=3), matrix(c(4,0,4, 8,4,8, 4,0,4), nrow=3) ) strength.test(tables) ```

DiffXTables documentation built on May 16, 2021, 9:07 a.m.