KAT.coin: Conditional Inference for the Kernel Association Test (KAT)

KAT.coinR Documentation

Conditional Inference for the Kernel Association Test (KAT)

Description

Computes the asymptotic and the approximate conditional p-values for the kernel association test

Usage

KAT.coin(y, G, X = NULL, out_type = "D", distribution = "asymptotic", B = 1000)

Arguments

y

a vector of phenotype on n subjects.

G

an n \times m matrix of SNP genotypes of n study subjects at m loci.

X

a matrix of covariates. It has n rows.

out_type

an indicator of the outcome type. "C" for the continuous outcome and "D" for the dichotomous outcome.

distribution

a character, the conditional null distribution of the test statistic can be approximated by its asymptotic distribution ("asymptotic", default) or via Monte Carlo resampling ("approximate"), as in package coin.

B

the number of permutations if distribution = "approximate".

Details

The asymptotic conditional null distribution is obtained using results in Strasser and Weber (1999). The p-value based on this distribution is computed using Davies' method.

Value

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

* statistic the value of the kernel association test statistic.

* parameter sample size and the number of SNPs.

* p.value the p-value based on the asymptotic or the approximate conditional null distribution.

* method a character string indicting the test performed.

* data.name a character string giving the name of the data.

Author(s)

Kai Wang <kai-wang@uiowa.edu>

References

Strasser, H. and Weber, C. (1999) On the asymptotic theory of permutation statistics. Mathematical Methods of Statistics. 8(2):220-250.

Wang, K. (2017) Conditional Inference for the Kernel Association Test. Bioinformatics 33 (23), 3733-3739.

Examples

n=1000
y = c(rep(1, n/2), rep(0, n/2))
maf = seq(0.05, 0.5, 0.05)
g = NULL
for (j in 1:10){
   geno.freq = c(maf[j]^2, 2*maf[j]*(1-maf[j]), (1-maf[j])^2)
   g = cbind(g, sample(c(0,1,2), n, replace=TRUE, prob=geno.freq))
   }
KAT.coin(y, g, X=NULL, out_type="D", B=1000)


iGasso documentation built on Aug. 8, 2023, 5:11 p.m.