Search in sources :

Example 1 with SGTFilter

use of com.hartwig.hmftools.common.variant.filter.SGTFilter in project hmftools by hartwigmedical.

the class PurityPloidyEstimateApplication method somaticVariants.

@NotNull
private static List<SomaticVariant> somaticVariants(@NotNull final ConfigSupplier configSupplier) throws IOException {
    final SomaticConfig config = configSupplier.somaticConfig();
    if (config.file().isPresent()) {
        String filename = config.file().get().toString();
        LOGGER.info("Loading somatic variants from {}", filename);
        SomaticVariantFactory factory = SomaticVariantFactory.filteredInstance(new PassingVariantFilter(), new NTFilter(), new SGTFilter());
        return factory.fromVCFFile(configSupplier.commonConfig().tumorSample(), filename);
    } else {
        LOGGER.info("Somatic variants support disabled.");
        return Collections.emptyList();
    }
}
Also used : SomaticConfig(com.hartwig.hmftools.purple.config.SomaticConfig) SGTFilter(com.hartwig.hmftools.common.variant.filter.SGTFilter) SomaticVariantFactory(com.hartwig.hmftools.common.variant.SomaticVariantFactory) PurityAdjustedSomaticVariantFactory(com.hartwig.hmftools.common.variant.PurityAdjustedSomaticVariantFactory) PassingVariantFilter(htsjdk.variant.variantcontext.filter.PassingVariantFilter) NTFilter(com.hartwig.hmftools.common.variant.filter.NTFilter) NotNull(org.jetbrains.annotations.NotNull)

Aggregations

PurityAdjustedSomaticVariantFactory (com.hartwig.hmftools.common.variant.PurityAdjustedSomaticVariantFactory)1 SomaticVariantFactory (com.hartwig.hmftools.common.variant.SomaticVariantFactory)1 NTFilter (com.hartwig.hmftools.common.variant.filter.NTFilter)1 SGTFilter (com.hartwig.hmftools.common.variant.filter.SGTFilter)1 SomaticConfig (com.hartwig.hmftools.purple.config.SomaticConfig)1 PassingVariantFilter (htsjdk.variant.variantcontext.filter.PassingVariantFilter)1 NotNull (org.jetbrains.annotations.NotNull)1