calculate.probabilities | R Documentation |
Help function to calculate expression probability, power and detection power for a given gamma distribution plus additional parameters
calculate.probabilities(
nSamples,
ctCells,
type,
ref.study,
ref.study.name,
gamma.parameters,
disp.fun,
min.UMI.counts,
perc.indiv.expr,
cutoffVersion,
nGenes,
samplingMethod,
sign.threshold,
MTmethod,
useSimulatedPower,
simThreshold,
speedPowerCalc,
indepSNPs,
ssize.ratio.de,
returnResultsDetailed
)
nSamples |
Sample size |
ctCells |
Number of cells of the target cell type |
type |
(eqtl/de) study |
ref.study |
Data frame with reference studies to be used for expression ranks and effect sizes (required columns: name (study name), rank (expression rank), FoldChange (DE study) /Rsq (eQTL study)) |
ref.study.name |
Name of the reference study. Will be checked in the ref.study data frame for it (as column name). |
gamma.parameters |
Data frame with gamma parameters, filtered for the correct cell type (required columns: ct (cell type), s1, r1, s2, r2, p1, p2/p3 (gamma parameters for both components)) |
disp.fun |
Function to fit the dispersion parameter dependent on the mean, filtered for the correct cell type (required columns: ct (cell type), asymptDisp, extraPois (both from taken from DEseq)) |
min.UMI.counts |
Expression cutoff in one individual: if cutoffVersion=absolute, more than this number of UMI counts for each gene per individual and cell type is required; if cutoffVersion=percentage, more than this percentage of cells need to have a count value large than 0 |
perc.indiv.expr |
Expression cutoff on the population level: if number < 1, percentage of individuals that need to have this gene expressed to define it as globally expressed; if number >=1 absolute number of individuals that need to have this gene expressed |
cutoffVersion |
Either "absolute" or "percentage" leading to different interpretations of min.counts (see description above) |
nGenes |
Number of genes to simulate (should match the number of genes used for the fitting) |
samplingMethod |
Approach to sample the gene mean values (either taking quantiles or random sampling) |
sign.threshold |
Significance threshold |
MTmethod |
Multiple testing correction method (possible options: "Bonferroni","FDR","none") |
useSimulatedPower |
Option to simulate eQTL power for small mean values to increase accuracy (only possible for eQTL analysis) |
simThreshold |
Threshold until which the simulated power is taken instead of the analytic (only for the eQTL analysis) |
speedPowerCalc |
Option to speed power calculation by skipping all genes with an expression probability less than 0.01 (as overall power is anyway close to 0) |
indepSNPs |
Number of independent SNPs assumed for each loci (for eQTL Bonferroni multiple testing correction the number of tests are estimated as number expressed genes * indepSNPs) |
ssize.ratio.de |
In the DE case, ratio between sample size of group 0 (control group) and group 1 (1=balanced design) |
returnResultsDetailed |
If true, return not only summary data frame, but additional list with exact probability vectors |
Power to detect the DE/eQTL genes from the reference study in a single cell experiment with these parameters
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.