|
|
@@ -318,6 +318,15 @@ impl Variants {
|
|
|
debug!("Successfully loaded variants from {}", filename);
|
|
|
Ok(variants)
|
|
|
}
|
|
|
+
|
|
|
+ pub fn get_alteration_cat(&self, cat: AlterationCategory) -> Vec<Variant> {
|
|
|
+ self
|
|
|
+ .data
|
|
|
+ .iter()
|
|
|
+ .filter(|v| v.alteration_category().contains(&cat))
|
|
|
+ .cloned()
|
|
|
+ .collect()
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
fn create_variant(vcf_variants: Vec<VcfVariant>, annotations: &Annotations) -> Variant {
|