VariationCall
HapLink.VariationCall — TypeVariationCallRepresents a Variation that is supported by aligned reads with sufficient metadata to support or refute its validity. It is designed to be converted into a line in Variant Call Format, or a VCF.Record.
Fields
variation::Variation: TheVariationof this callquality::Union{Nothing,Number}: Phred quality of the basecall forvariationfilter::Vector{String}: Indicator ifvariationhas passed filters and is actually a variant call, or a list of criteria that have failed itdepth::Union{Nothing,UInt}: The number of reads that coverleftposition(variation)strandbias::Union{Nothing,Float64}: The fraction of timesvariationappears on a positive strandaltdepth::Union{Nothing,UInt}: The number of typesvariationoccursreadpos::Union{Nothing,UInt}: The averagerelative position ofvariationin each readpvalue::Union{Nothing,Float64}: The Fisher's Exact Test $p$-value of this call
HapLink.altdepth — Methodaltdepth(vc::VariationCall) -> Union{Nothing,UInt}Gets the number of times vc appears. Returns nothing if unknown.
See also altdepth(::VariationPileup)
HapLink.call_variant — Methodcall_variant(
pileup::VariationPileup,
α::Float64;
D::Union{Nothing,Int}=nothing,
Q::Union{Nothing,Float64}=nothing,
X::Union{Nothing,Float64}=nothing,
F::Union{Nothing,Float64}=nothing,
S::Union{Nothing,Float64}=nothing,
) -> VariationCallCalls variant from a pileup.
Arguments
pileup::VariationPileup: The pileup to call variants fromα::Float64: Fisher's Exact Test significance ($α$) level to call variants
Keywords
Leave any keyword undefined to skip filtering based on that field
D::Union{Nothing,Int}=nothing: Minimum total read depth for a variant to be calledQ::Union{Nothing,Float64}=nothing: Minimum average Phred quality for a variant to be calledX::Union{Nothing,Float64}=nothing: Maximum average distance variant can be from read edge to be calledF::Union{Nothing,Float64}=nothing: Minimum alternate frequency for a variant to be calledS::Union{Nothing,Float64}=nothing: Maximum proportion of the number of times variant can appear on one strand versus the other
HapLink.depth — Methoddepth(vc::VariationCall) -> Union{Nothing,UInt}Gets the number of times the position of vc appears total. Returns nothing if unknown.
See also depth(::VariationPileup)
HapLink.filters — Methodfilters(vc::VariationCall) -> Vector{String}Gets all filters that have been applied to vc. Note that an empty FILTER entry is not permitted under the VCF spec, and an empty array should not automatically be considered to have PASSed all filters.
HapLink.frequency — Methodfrequency(vc::VariationCall) -> Float64Gets the alternate allele frequency of vc
See also frequency(::VariationPileup)
HapLink.p_value — Methodp_value(vc::VariationCall) -> Union{Nothing,Float64}Gets the $p$-value of the observed statistic of vc. Returns nothing if unknown.
See also variation_test
HapLink.quality — Methodquality(vc::VariationCall) -> Union{Nothing,Float64}Gets the average phred quality score of vc, if known. Returns nothing if unknown.
See also quality(::VariationInfo), quality(::VariationPileup)
HapLink.readpos — Methodreadpos(vc::VariationCall) -> Union{Nothing,Float64}Gets the average relative position of vc. Returns nothing if unknown.
See also readpos(::VariationPileup)
HapLink.strand_bias — Methodstrand_bias(vc::VariationCall) -> Union{Nothing,Float64}Gets the fraction of times vc appears on the positive strand. Returns nothing if unknown.
HapLink.variation — Methodvariation(vc::VariationCall) -> SequenceVariation.VariationGets the Variation of a VariationCall
HapLink.variation_test — Methodvariation_test(depth::Int, altdepth::Int, quality::Float64)Conducts a Fisher's Exact Test to deterimine the likelihood of a variant with total depth and variation depth altdepth occuring, given an average basecall quality. Returns the $p$-value of the test.
HapLink.vcf — Methodvcf(vc::VariationCall, refname::AbstractString) -> VCF.RecordConverts vc into a VCF.Record. refname is required and used as the CHROM field in the record.