Search in sources :

Example 6 with MultiAllelicResultFilter

use of org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter in project molgenis by molgenis.

the class MultiAllelicResultFilterTest method filterResultsTest11.

@Test
public void filterResultsTest11() {
    MultiAllelicResultFilter filter = new MultiAllelicResultFilter(Collections.singletonList(attributeFactory.create().setName("annotation").setDataType(STRING)), vcfAttributes);
    Optional<Entity> result = filter.filterResults(Collections.singletonList(resultEntity9), entity9, false);
    assertEquals(Lists.newArrayList(result.asSet()).get(0).getString("annotation"), "16");
}
Also used : DynamicEntity(org.molgenis.data.support.DynamicEntity) Entity(org.molgenis.data.Entity) MultiAllelicResultFilter(org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter) Test(org.testng.annotations.Test) AbstractMolgenisSpringTest(org.molgenis.data.AbstractMolgenisSpringTest)

Example 7 with MultiAllelicResultFilter

use of org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter in project molgenis by molgenis.

the class MultiAllelicResultFilterTest method filterResultsTest1.

@Test
public void filterResultsTest1() {
    MultiAllelicResultFilter filter = new MultiAllelicResultFilter(Collections.singletonList(attributeFactory.create().setName("annotation").setDataType(STRING)), vcfAttributes);
    Optional<Entity> result1 = filter.filterResults(Collections.singletonList(resultEntity1), entity1, false);
    assertEquals(Lists.newArrayList(result1.asSet()).get(0).getString("annotation"), "1");
}
Also used : DynamicEntity(org.molgenis.data.support.DynamicEntity) Entity(org.molgenis.data.Entity) MultiAllelicResultFilter(org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter) Test(org.testng.annotations.Test) AbstractMolgenisSpringTest(org.molgenis.data.AbstractMolgenisSpringTest)

Example 8 with MultiAllelicResultFilter

use of org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter in project molgenis by molgenis.

the class MultiAllelicResultFilterTest method filterResultsTest7.

@Test
public void filterResultsTest7() {
    MultiAllelicResultFilter filter = new MultiAllelicResultFilter(Collections.singletonList(attributeFactory.create().setName("annotation").setDataType(STRING)), vcfAttributes);
    Optional<Entity> result7 = filter.filterResults(Collections.singletonList(resultEntity6), entity3, false);
    assertEquals(Lists.newArrayList(result7.asSet()).get(0).getString("annotation"), "11,.,10");
}
Also used : DynamicEntity(org.molgenis.data.support.DynamicEntity) Entity(org.molgenis.data.Entity) MultiAllelicResultFilter(org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter) Test(org.testng.annotations.Test) AbstractMolgenisSpringTest(org.molgenis.data.AbstractMolgenisSpringTest)

Example 9 with MultiAllelicResultFilter

use of org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter in project molgenis by molgenis.

the class CaddAnnotator method init.

@Override
public void init() {
    List<Attribute> attributes = createCaddAnnotatorAttributes();
    AnnotatorInfo caddInfo = AnnotatorInfo.create(AnnotatorInfo.Status.READY, AnnotatorInfo.Type.PATHOGENICITY_ESTIMATE, NAME, "CADD is a tool for scoring the deleteriousness of single nucleotide variants as well as insertion/deletions variants in the human genome.\n" + "While many variant annotation and scoring utils are around, most annotations tend to exploit a single information type (e.g. conservation) " + "and/or are restricted in scope (e.g. to missense changes). " + "Thus, a broadly applicable metric that objectively weights and integrates diverse information is needed. " + "Combined Annotation Dependent Depletion (CADD) is a framework that integrates multiple " + "annotations into one metric by contrasting variants that survived natural selection with simulated mutations.\n" + "C-scores strongly correlate with allelic diversity, pathogenicity of both coding and non-coding variants, and experimentally measured " + "regulatory effects, and also highly rank causal variants within " + "individual genome sequences. Finally, C-scores of complex trait-associated variants from genome-wide association studies (GWAS) are " + "significantly higher than matched controls and correlate with study sample size, likely reflecting the increased accuracy of larger GWAS.\n" + "CADD can quantitatively prioritize functional, deleterious, and disease causal variants across a wide range of functional categories, " + "effect sizes and genetic architectures and can be used prioritize " + "causal variation in both research and clinical settings. (source: http://cadd.gs.washington.edu/info)", attributes);
    EntityAnnotator entityAnnotator = new AbstractAnnotator(CADD_TABIX_RESOURCE, caddInfo, new LocusQueryCreator(vcfAttributes), new MultiAllelicResultFilter(attributes, true, vcfAttributes), dataService, resources, new SingleFileLocationCmdLineAnnotatorSettingsConfigurer(CaddAnnotatorSettings.Meta.CADD_LOCATION, caddAnnotatorSettings)) {

        @Override
        public List<Attribute> createAnnotatorAttributes(AttributeFactory attributeFactory) {
            return createCaddAnnotatorAttributes();
        }
    };
    annotator.init(entityAnnotator);
}
Also used : LocusQueryCreator(org.molgenis.data.annotation.core.query.LocusQueryCreator) Attribute(org.molgenis.data.meta.model.Attribute) EntityAnnotator(org.molgenis.data.annotation.core.entity.EntityAnnotator) MultiAllelicResultFilter(org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter) AbstractAnnotator(org.molgenis.data.annotation.core.entity.impl.framework.AbstractAnnotator) AnnotatorInfo(org.molgenis.data.annotation.core.entity.AnnotatorInfo) AttributeFactory(org.molgenis.data.meta.model.AttributeFactory) SingleFileLocationCmdLineAnnotatorSettingsConfigurer(org.molgenis.data.annotation.web.settings.SingleFileLocationCmdLineAnnotatorSettingsConfigurer)

Example 10 with MultiAllelicResultFilter

use of org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter in project molgenis by molgenis.

the class FitConAnnotator method init.

@Override
public void init() {
    List<Attribute> attributes = createFitconOutputAttributes();
    AnnotatorInfo fitconInfo = AnnotatorInfo.create(AnnotatorInfo.Status.READY, AnnotatorInfo.Type.EFFECT_PREDICTION, NAME, "Summary: Annotating genetic variants, especially non-coding variants, " + "for the purpose of identifying pathogenic variants remains a challenge. " + "Combined annotation-dependent depletion (CADD) is an al- gorithm designed " + "to annotate both coding and non-coding variants, and has been shown to " + "outper- form other annotation algorithms. CADD trains a linear kernel support" + " vector machine (SVM) to dif- ferentiate evolutionarily derived, likely benign," + " alleles from simulated, likely deleterious, variants. However, SVMs cannot " + "capture non-linear relationships among the features, which can limit per- formance. " + "To address this issue, we have developed FITCON. FITCON uses the same feature set and " + "training data as CADD to train a deep neural network (DNN). DNNs can capture non-linear" + " relation- ships among features and are better suited than SVMs for problems with a " + "large number of samples and features. We exploit Compute Unified Device Architecture-compatible" + " graphics processing units and deep learning techniques such as dropout and momentum training to" + " accelerate the DNN train- ing. FITCON achieves about a 19%relative reduction in the error rate and" + " about a 14%relative increase in the area under the curve (AUC) metric over CADD’s SVMmethodology." + " All data and source code are available at https://cbcl.ics.uci.edu/ public_data/FITCON/. Contact:", attributes);
    EntityAnnotator entityAnnotator = new AbstractAnnotator(FITCON_TABIX_RESOURCE, fitconInfo, new LocusQueryCreator(vcfAttributes), new MultiAllelicResultFilter(attributes, vcfAttributes), dataService, resources, new SingleFileLocationCmdLineAnnotatorSettingsConfigurer(FITCON_LOCATION, fitConAnnotatorSettings)) {

        @Override
        public List<Attribute> createAnnotatorAttributes(AttributeFactory attributeFactory) {
            return createFitconOutputAttributes();
        }
    };
    annotator.init(entityAnnotator);
}
Also used : LocusQueryCreator(org.molgenis.data.annotation.core.query.LocusQueryCreator) Attribute(org.molgenis.data.meta.model.Attribute) EntityAnnotator(org.molgenis.data.annotation.core.entity.EntityAnnotator) MultiAllelicResultFilter(org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter) AbstractAnnotator(org.molgenis.data.annotation.core.entity.impl.framework.AbstractAnnotator) AnnotatorInfo(org.molgenis.data.annotation.core.entity.AnnotatorInfo) AttributeFactory(org.molgenis.data.meta.model.AttributeFactory) SingleFileLocationCmdLineAnnotatorSettingsConfigurer(org.molgenis.data.annotation.web.settings.SingleFileLocationCmdLineAnnotatorSettingsConfigurer)

Aggregations

MultiAllelicResultFilter (org.molgenis.data.annotation.core.filter.MultiAllelicResultFilter)21 AbstractMolgenisSpringTest (org.molgenis.data.AbstractMolgenisSpringTest)16 Entity (org.molgenis.data.Entity)16 Test (org.testng.annotations.Test)16 DynamicEntity (org.molgenis.data.support.DynamicEntity)14 AnnotatorInfo (org.molgenis.data.annotation.core.entity.AnnotatorInfo)5 EntityAnnotator (org.molgenis.data.annotation.core.entity.EntityAnnotator)5 AbstractAnnotator (org.molgenis.data.annotation.core.entity.impl.framework.AbstractAnnotator)5 LocusQueryCreator (org.molgenis.data.annotation.core.query.LocusQueryCreator)5 Attribute (org.molgenis.data.meta.model.Attribute)5 AttributeFactory (org.molgenis.data.meta.model.AttributeFactory)5 SingleFileLocationCmdLineAnnotatorSettingsConfigurer (org.molgenis.data.annotation.web.settings.SingleFileLocationCmdLineAnnotatorSettingsConfigurer)4 MolgenisDataException (org.molgenis.data.MolgenisDataException)2 Lists.newArrayList (com.google.common.collect.Lists.newArrayList)1 ArrayList (java.util.ArrayList)1 EntityType (org.molgenis.data.meta.model.EntityType)1