Learn R Programming

pcadapt (version 2.2)

computeStats: Test Statistics

Description

computeStats computes the test statistics for each genetic marker.

Usage

computeStats(data, res, method, nSNP, K, data.type, min.maf)

Arguments

data
a data matrix or a data frame if `PCAdapt = FALSE`.
res
a list of quantities among which are the loadings.
method
a character string that specifies the method used to compute the p-values.
nSNP
an integer specifying the number of genetic markers.
K
an integer specifying the number of principal components to retain.
data.type
a character string that specifies the type of data being read, either a genotype matrix (data.type="genotype"), or a matrix of allele frequencies (data.type="pool", or outputs from the software PCAdapt (data.t
min.maf
a value between 0 and 0.5 specifying the threshold of minor allele frequencies above which p-values are computed.

Examples

Run this code
## see ?pcadapt for examples

Run the code above in your browser using DataLab