monarch-initiative / biolink-api

API for linked biological knowledge
https://api.monarchinitiative.org/api/
BSD 3-Clause "New" or "Revised" License
63 stars 25 forks source link

Add endpoint for variant pivot table on relation (patho, likely patho) and gene given a disease ID #363

Open kshefchek opened 3 years ago

kshefchek commented 3 years ago

Use case: https://github.com/monarch-initiative/monarch-ui/issues/238

query example (marfans): https://solr-dev.monarchinitiative.org/solr/golr/select/?wt=json&facet=true&json.nl=arrarr&rows=0&q=*:*&facet.pivot=subject_gene_label,relation_label&fq=object_closure:%22MONDO:0007947%22&fq=association_type:variant_disease&facet.pivot=subject_gene_label,subject_gene

We should also support filtering over the clinvar confidence score/star system, which can be accessed via the 'confidence score' field in solr, eg:

Filter out any variants under 2 stars: https://solr-dev.monarchinitiative.org/solr/golr/select/?wt=json&facet=true&json.nl=arrarr&rows=0&q=*:*&facet.pivot=subject_gene_label,relation_label&fq=object_closure:%22MONDO:0007947%22&fq=association_type:variant_disease&facet.pivot=subject_gene_label,subject_gene&fq=confidence_score:[2%20TO%205]

Sounds like @iimpulse has made a start on the ontobio side