mirror of
https://github.com/MillironX/SequenceVariation.jl.git
synced 2024-12-22 08:28:16 +00:00
Add documentation for haplotype reference switching
This commit is contained in:
parent
ecaa995d2b
commit
d0f55742d6
1 changed files with 15 additions and 0 deletions
|
@ -38,3 +38,18 @@ human2 = reconstruct(bos_human_haplotype)
|
|||
human2 == bovine
|
||||
human2 == human
|
||||
```
|
||||
|
||||
## Reference switching
|
||||
|
||||
All variations within a haplotype can be mapped to a new reference sequence
|
||||
given an alignment between the new and old references using the
|
||||
[`translate`](@ref translate(::Haplotype{S,T}, ::PairwiseAlignment{S,S}) where {S,T})
|
||||
function. This could be useful if variants were called against a reference
|
||||
sequence for the entire species, but need to be analyzed as variants of a
|
||||
subtype later.
|
||||
|
||||
```@repl call_variants
|
||||
ovis_human_alignment =
|
||||
PairwiseAlignment(AlignedSequence(human, Alignment("32M", 1, 1)), ovine)
|
||||
SequenceVariation.translate(bos_ovis_haplotype, ovis_human_alignment)
|
||||
```
|
||||
|
|
Loading…
Reference in a new issue