pub struct FilterParams {
pub filter_on: Option<bool>,
pub abun_filter: (Option<u32>, Option<u32>),
pub err_filter: f64,
pub strand_filter: f64,
}Expand description
Used to pass around filter options for sketching
Fields§
§filter_on: Option<bool>§abun_filter: (Option<u32>, Option<u32>)§err_filter: f64§strand_filter: f64Implementations§
Source§impl FilterParams
impl FilterParams
Sourcepub fn filter_sketch(&self, sketch: &mut Sketch)
pub fn filter_sketch(&self, sketch: &mut Sketch)
Filter the sketch according to these FilterParams
Sourcepub fn filter_counts(&mut self, hashes: &[KmerCount]) -> Vec<KmerCount>
pub fn filter_counts(&mut self, hashes: &[KmerCount]) -> Vec<KmerCount>
Returns the filtered kmer counts.
If the err filter determined a different low_abundance_filter update self to that one.
pub fn to_serialized(&self) -> HashMap<String, String>
pub fn from_serialized(filters: &HashMap<String, String>) -> FinchResult<Self>
Trait Implementations§
Source§impl Clone for FilterParams
impl Clone for FilterParams
Source§fn clone(&self) -> FilterParams
fn clone(&self) -> FilterParams
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FilterParams
impl Debug for FilterParams
Source§impl Default for FilterParams
impl Default for FilterParams
Source§impl PartialEq for FilterParams
impl PartialEq for FilterParams
impl StructuralPartialEq for FilterParams
Auto Trait Implementations§
impl Freeze for FilterParams
impl RefUnwindSafe for FilterParams
impl Send for FilterParams
impl Sync for FilterParams
impl Unpin for FilterParams
impl UnwindSafe for FilterParams
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more