This function implements rare variant test with full MIRAGE model with both variant and gene level
mirage(
data,
n1,
n2,
gamma = 3,
sigma = 2,
eta.init = 0.1,
delta.init = 0.1,
estimate.delta = TRUE,
estimate.eta = TRUE,
fixed.eta = NULL,
max.iter = 10000,
tol = 1e-05,
verbose = TRUE
)
variant count data, a 5 column data frame for 1) locus ID, 2) Gene 3) count in cases, 4) count in controls and 5) variant category index for a variant. The 1st column is optional.
sample size in cases.
sample size in controls.
a list of category specific hyper prior shape parameter in Beta distribution for effect size, or a numeric value if all category share the same effect size.
a list of category specific hyper prior scale parameter in Beta distribution for effect size, or a numeric value if all category share the same effect size.
initial value for prior on proportion of risk variants in a variant set.
initial value for prior on proportion of risk genes. Must be a positive number between 0 and 1.
When TRUE delta is to be estimated and FALSE delta is fixed at delta.init
When TRUE eta is to be estimated and FALSE eta is fixed.eta MUST be provided and BF per gene will be reported.
fixed.eta must be provided when estimate.eta is false
maximum number of iterations enforcing EM algorithm to stop
threshold of parameter estimate difference to determine the convergence of EM algorithm
Bayes factor and posterior probability of genes
Estimate for proportion of risk genes and p values
Estimate for proportion of risk variants in a variant group and p values
a list of Bayes factor for all variants in a gene
# see example at https://xinhe-lab.github.io/mirage/articles/mwe.html