use of org.molgenis.data.annotation.core.filter.ClinvarMultiAllelicResultFilter in project molgenis by molgenis.
the class ClinvarAnnotator method init.
@Override
public void init() {
List<Attribute> attributes = createClinvarOutputAttributes();
AnnotatorInfo clinvarInfo = AnnotatorInfo.create(Status.READY, AnnotatorInfo.Type.PATHOGENICITY_ESTIMATE, NAME, " ClinVar is a freely accessible, public archive of reports of the relationships" + " among human variations and phenotypes, with supporting evidence. ClinVar thus facilitates" + " access to and communication about the relationships asserted between human variation and " + "observed health status, and the history of that interpretation. ClinVar collects reports " + "of variants found in patient samples, assertions made regarding their clinical significance, " + "information about the submitter, and other supporting data. The alleles described in submissions " + "are mapped to reference sequences, and reported according to the HGVS standard. ClinVar then " + "presents the data for interactive users as well as those wishing to use ClinVar in daily " + "workflows and other local applications. ClinVar works in collaboration with interested " + "organizations to meet the needs of the medical genetics community as efficiently and effectively " + "as possible. Information about using ClinVar is available at: http://www.ncbi.nlm.nih.gov/clinvar/docs/help/.", attributes);
LocusQueryCreator locusQueryCreator = new LocusQueryCreator(vcfAttributes);
ClinvarMultiAllelicResultFilter clinvarMultiAllelicResultFilter = new ClinvarMultiAllelicResultFilter(vcfAttributes);
EntityAnnotator entityAnnotator = new AbstractAnnotator(CLINVAR_TABIX_RESOURCE, clinvarInfo, locusQueryCreator, clinvarMultiAllelicResultFilter, dataService, resources, new SingleFileLocationCmdLineAnnotatorSettingsConfigurer(CLINVAR_LOCATION, clinvarAnnotatorSettings)) {
@Override
public List<Attribute> createAnnotatorAttributes(AttributeFactory attributeFactory) {
return createClinvarOutputAttributes();
}
@Override
protected Object getResourceAttributeValue(Attribute attr, Entity sourceEntity) {
String attrName;
if (CLINVAR_CLNSIG.equals(attr.getName())) {
attrName = CLINVAR_CLNSIG_ResourceAttributeName;
} else if (CLINVAR_CLNALLE.equals(attr.getName())) {
attrName = CLINVAR_CLINALL_ResourceAttributeName;
} else {
attrName = attr.getName();
}
return sourceEntity.get(attrName);
}
};
annotator.init(entityAnnotator);
}
Aggregations