# HG changeset patch # User nick # Date 1370018068 14400 # Node ID 933a9435939c282de4f9fbd0ba2a74311851c4d5 # Parent 318fdf77aa5483c859eedfd0ebadaa526f2c4379 Current xml - includes documentation diff -r 318fdf77aa54 -r 933a9435939c allele-counts.xml --- a/allele-counts.xml Fri May 31 12:33:48 2013 -0400 +++ b/allele-counts.xml Fri May 31 12:34:28 2013 -0400 @@ -3,9 +3,9 @@ allele-counts.py -i $input -o $output -f $freq -c $covg $header - + - + @@ -16,9 +16,72 @@ -This tool parses the output of Naive Variant Detector, counting variants, calculating numbers of alleles, and minor allele frequency. It applies filters based on coverage, strand bias, and minor allele frequency cutoffs. + +.. class:: warningmark + +**Note** + +This will only process a special type of VCF file. The VCF must have a special genotype field in the sample columns, giving the number of each type of variant. Also, the variant data **must be stranded**. + +The Naive Variant Detector tool produces this VCF format, and is the normal upstream tool from this one. + +----- + +.. class:: infomark + +**What it does** + +This tool parses variant counts from a special VCF file (normally the output of the Naive Variant Detector tool). It counts simple (ACGT) variants, calculates numbers of alleles, and calculates minor allele frequency. It applies filters based on coverage, strand bias, and minor allele frequency cutoffs. + +----- + +.. class:: infomark + +**Output columns** + +Each row represents one site in one sample. 12 fields give information about that site:: -**Note**: The VCF file from the Naive Variant Detector must include counts *per strand*. + 1. SAMPLE - Sample names (from VCF sample column labels) + 2. CHR - Chromosome of the site + 3. POS - Chromosomal coordinate of the site + 4. A - Number of reads supporting an 'A' + 5. C - ditto, for 'C' + 6. G - ditto, for 'G' + 7. T - ditto, for 'T' + 8. CVRG - Total (number of reads supporting one of the four bases above) + 9. ALLELES - Number of qualifying alleles + 10. MAJOR - Major allele base + 11. MINOR - Minor allele base (2nd most prevalent variant) + 12. MINOR.FREQ.PERC. - Frequency of minor allele + +**Example**:: + SAMPLE CHR POS A C G T CVRG ALLELES MAJOR MINOR MINOR.FREQ.PERC. + BLOOD_3 chr7 10980 11 88 1 0 100 2 C A 0.11 + +----- + +.. class:: warningmark + +**Site printing and allele tallying requirements** + +Each line is printed only when the site is covered by the threshold number of reads **on each strand**. If coverage of either strand is below the threshold, the line (sample + site combination) is omitted. + +**N.B.**: This means the total coverage for each printed site will be at least twice the number you give in the "coverage threshold" option. + +Also, reads supporting a variant outside the canonical 4 nucleotides will not count towards the coverage requirement. For instance, a site covered by 150 reads on each strand, the majority of which support an indel variant, will not be printed. + +Alleles are only counted in the column 9 tally if they meet or exceed the minor allele frequency threshold. In addition, the alleles passing the threshold on each strand have to match (though not in order). Otherwise, the allele count will be 0. The reported minor allele and minor allele frequency, though, will always be reported. + +However, if there is a tie for the minor allele (between the 2nd and 3rd most common alleles), the minor allele will be reporated as 'N', and the frequency as 0. + +----- + +.. class:: infomark + +**Additional notes** + + + \ No newline at end of file