Permutation TTest Algorithm

Performed on a set of non-negative numbers and labels of size N. There must be two specific labels. Label 1 must be 1 and label 2 must be 2. There can also be any other labels that will be ignored.

Permutation T value

  1. Find the number and sum of each group.
    • Na: number of values in group 1
    • Nb: number of values in group 2
    • Sa: $\sum X_i$
    • Sb: $\sum Y_i$
    • SSa: $\sum {X_i}^2$
    • SSb: $\sum {Y_i}^2$
  2. Compute the sample mean of each group.
    • Ma: $\frac{Sa}{Na}$
    • Mb: $\frac{Sb}{Nb}$
  3. Compute the variance for each group.
  4. Estimate the variance
    • varA: $SSa - \frac{Sa^2}{Na}$
    • varB: $SSb - \frac{Sb^2}{Nb}$
    • Var: $\frac{varA + varB}{Na + Nb - 2}$
  5. Estimate the standard deviation (stDev): $\sqrt{\frac{Var}{Na} + \frac{Var}{Nb}}$
  6. t: $\frac{Ma - Mb}{stDev}$

Permutation T probability

  1. Calculate raw P value based on original grouping of each gene.
    $P_0$ = $2 * (1 - probt(|t|, Na + Nb - 2))$
  2. Randomly regrouping each gene.
    The size in each group stays the same as the original, each sample can only appare once in each group, number of regrouping depends on user.
  3. For each regrouped gene, recalculate P value.
    $P_n$ = $2 * (1 - probt(|t|, Na + Nb - 2))$
  4. Count if $P_n$ less than or equals to $P_0$.
    count = number of $P_n$ <= $P_0$
  5. Calculate permutation P value.
    PP-value = $ \frac{count}{NumRegrouping}$
  6. Rank PP-value by ascending order, calculate False Discovery Rate P value.
    FDR P-value = $ \frac{TotalNumOfGene}{rank}$*PP-value

summary of running time

sample size group size permutation time running time
10 5 vs. 5 252 0.01
10 5 vs. 5 5,000 0.406
20 10 vs. 10 10,000 0.56
20 10 vs. 10 1,847,560 87.746
50 25 vs. 25 10,000 1.261
50 25 vs. 25 50,000 14.703

-- JoanZhang - 16 Aug 2004

This topic: Main > Projects > MicroArrayMassSpec > GeneralWfccmDesign > WfccmAlgorithmPermutationTTest
Topic revision: revision 3
 
This site is powered by FoswikiCopyright © 2013-2022 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Vanderbilt Biostatistics Wiki? Send feedback