pub struct AlignmentResult {
pub score: i32,
pub aligned_query: Vec<u8>,
pub aligned_target: Vec<u8>,
pub query_start: usize,
pub query_end: usize,
pub target_start: usize,
pub target_end: usize,
pub cigar: Vec<CigarOp>,
}Expand description
The result of a pairwise sequence alignment.
Fields§
§score: i32Alignment score.
aligned_query: Vec<u8>Aligned query sequence (with - for gaps).
aligned_target: Vec<u8>Aligned target sequence (with - for gaps).
query_start: usizeStart position in the original query (0-based, inclusive).
query_end: usizeEnd position in the original query (0-based, exclusive).
target_start: usizeStart position in the original target (0-based, inclusive).
target_end: usizeEnd position in the original target (0-based, exclusive).
cigar: Vec<CigarOp>CIGAR operations describing the alignment.
Implementations§
Source§impl AlignmentResult
impl AlignmentResult
Sourcepub fn cigar_string(&self) -> String
pub fn cigar_string(&self) -> String
Format the CIGAR vector as a compact string, e.g. "4=1I3=".
Sourcepub fn identity(&self) -> f64
pub fn identity(&self) -> f64
Fraction of aligned columns that are exact matches, in [0.0, 1.0].
Returns 0.0 if the alignment is empty.
Sourcepub fn mismatches(&self) -> usize
pub fn mismatches(&self) -> usize
Number of mismatching positions.
Trait Implementations§
Source§impl Clone for AlignmentResult
impl Clone for AlignmentResult
Source§impl Debug for AlignmentResult
impl Debug for AlignmentResult
Auto Trait Implementations§
impl Forget for AlignmentResult
impl Freeze for AlignmentResult
impl Move for AlignmentResult
impl RefUnwindSafe for AlignmentResult
impl Send for AlignmentResultwhere
RawVecInner: Send,
impl Sync for AlignmentResultwhere
RawVecInner: Sync,
impl Unpin for AlignmentResult
impl UnsafeUnpin for AlignmentResultwhere
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<CigarOp>: UnsafeUnpin,
impl UnwindSafe for AlignmentResultwhere
RawVecInner: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more