Primo_chiMix: Estimate posterior probabilities of association patterns,...

Description Usage Arguments Details Value

View source: R/main.R

Description

For each observation (e.g. SNP), estimates the posterior probability of each association pattern. This version of the function uses a mixture of chi-squared statistics and the parameters of the alternative distributions which were previously calculated (i.e. using estimate_densities_pval). It is useful for cases where the same statistic from one study (e.g. gene-SNP pair) may be mapped to multiple statistics from another study (e.g. multiple gene-CpG pairings). Utilizes parallel computing, when available.

Usage

1
Primo_chiMix(chi_mix, A, df_alt, Gamma, tol = 0.001, par_size = 1)

Arguments

chi_mix

matrix of -2log(P)-values from test statistics.

A

vector of scaling factors under the alternative distributions.

df_alt

vector of degrees of freedom approximated for the alternative distributions.

Gamma

correlation matrix.

tol

numeric value specifying tolerance threshold for convergence.

par_size

numeric value specifying the number of workers for parallel computing (1 for sequential processing).

Details

The following are additional details describing the input arguments (for m SNPs/observations measured in d studies):

chi_mix m x d matrix.
A vector of length d.
df_alt vector of length d.
Gamma d x d matrix.

Value

A list with the following elements:

post_prob matrix of posterior probabilities (each column corresponds to an association pattern).
pis vector of estimated proportion of observations belonging to each association pattern.
D_mat matrix of densities under each association pattern.
Gamma correlation matrix.
chi_mix matrix of -2log(P)-values.
A vector of scaling factors under the alternative distributions.
df_alt vector of degrees of freedom approximated for the alternative distributions.

The main element of interest for inference is the posterior probabilities matrix, post_prob. The estimated proportion of observations belonging to each association pattern, pis, may also be of interest. The remaining elements are returned primarily for use by other functions.


kjgleason/primo documentation built on Sept. 7, 2021, 5:21 p.m.