Tajima's D 中性进化检验
Posted hjbreg
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Tajima's D 中性进化检验相关的知识,希望对你有一定的参考价值。
Tajima F (1989) Genetics 123:585-595
1 Average number of pairwise nucleotide differences
$$ hat k = frac{sumsum_{i<j} k_{ij}}{inom{n}{2}} $$
( k_{ij} ), the number of nucleotide differences between the $i$-th and $j$-th DNA sequences
2 D statistic
$$ D = frac{hat k - frac{S}{a_1}}{sqrt{e_1 S + e_2 S (S-1)}} $$
$$ a_1 = sum limits_{i=1}^{n-1} frac{1}{i} $$
$$ a_2 = sum limits_{i=1}^{n-1} frac{1}{i^2} $$
$$ b_1 = frac{n+1}{3(n-1)} $$
$$ b_2 = frac{2(n^2+n+3)}{9n(n-1)} $$
$$ c_1 = b_1 - frac{1}{a_1} $$
$$ c_2 = b_2 - frac{n+2}{a_1 n} + frac{a_2}{a_1^2} $$
$$ e_1 = frac{c_1}{a_1} $$
$$ e_2 = frac{c_2}{a_1^2 + a_2} $$
( S ), the number of segregating (or polymorphic) sites in the sample
3 计算
Tajima F (1989) Genetics 123:585-595
Carlson CS, et al. (2005) Genome Res 15:1553-1565
vcftools --vcf geno.cvf --TajimaD 100000
4 示例
一个 SNP 标记,5 个个体
A A C C C
两两个体间基因型差异
i | j | d |
1 | 2 | 0 |
1 | 3 | 1 |
1 | 4 | 1 |
1 | 5 | 1 |
2 | 3 | 1 |
2 | 4 | 1 |
2 | 5 | 1 |
3 | 4 | 0 |
3 | 5 | 0 |
4 | 5 | 0 |
( pi = n1*n2 / (n*(n-1)/2) = 2*n1*n2 / (n*(n-1)) = 2*2*3/(4*5) = 0.6 )
以上是关于Tajima's D 中性进化检验的主要内容,如果未能解决你的问题,请参考以下文章
python实现D‘Agostino‘s K-squared test正态分布检验
What's the difference between @Component, @Repository & @Service annotations in Spring?(代码片段