Closed buniello closed 2 years ago
On the cloud and also in this link: ftp://ftp.ebi.ac.uk/pub/databases/opentargets/genetics/latest/lut/study-index/
there are the annotations for each study. In this table there is also a column called "has_sumstats" which indicates whether a study has summary statistics or not
For use-case #1 above (Target/Gene page - Study Table and Coloc Table):
Example of API query (includes calls for both tables in Gene page) :
query GenePageQuery { geneInfo(geneId: "ENSG00000169174") { id symbol chromosome start end bioType typename } studiesAndLeadVariantsForGeneByL2G(geneId: "ENSG00000169174") { pval yProbaModel study { studyId traitReported pubAuthor pubDate pmid nInitial nReplication hasSumstats typename } variant { rsId id typename } odds { oddsCI oddsCILower oddsCIUpper typename } beta { betaCI betaCILower betaCIUpper direction typename } typename } colocalisationsForGene(geneId: "ENSG00000169174") { leftVariant { id rsId typename } study { studyId traitReported pubAuthor pubDate pmid hasSumstats typename } qtlStudyId phenotypeId tissue { id name typename } h3 h4 log2h4h3 typename } }
EXAMPLE RESPONSE for one study: "study": { "studyId": "GCST002221", "traitReported": "Cholesterol, total", "pubAuthor": "Willer CJ", "pubDate": "2013-10-06", "pmid": "PMID:24097068", "nInitial": 94595, "nReplication": 93982, "hasSumstats": true, "__typename": "Study" },
For use-case #3 above: Gene prioritisation page (evidence page) -add sumstats info in the Association Summary’ section, under "study details": -this is possible as endpoint "hasSumstats" is queried API query:
query StudyLocusHeaderQuery($studyId: String!, $variantId: String!) {
studyInfo(studyId: $studyId) {
studyId
traitReported
pubAuthor
pubDate
pubJournal
pmid
nInitial
nReplication
nCases
hasSumstats
__typename
}
variantInfo(variantId: $variantId) {
rsId
id
__typename
}
}
Example response:
{
"data": {
"studyInfo": {
"studyId": "GCST002222",
"traitReported": "LDL cholesterol",
"pubAuthor": "Willer CJ",
"pubDate": "2013-10-06",
"pubJournal": "Nat Genet",
"pmid": "PMID:24097068",
"nInitial": 94595,
"nReplication": 93982,
"nCases": null,
"hasSumstats": true,
"__typename": "Study"
},
"variantInfo": {
"rsId": "rs7254892",
"id": "19_44886339_G_A",
"__typename": "Variant"
}
}
}
For use-case #2 above: Variant page
Visualisation specs (for consistency with current style of table in Portal): HEADER: Sumstats VALUE: yes/no
N.B.: currently, the studies with sumstats are also visualised in blue in the searchbox dropdown when searching for a study. This visualisation will not be modified for now.
I can see the data (hasSumstats) is available - I'll start working on this
I have reviewed @LucaFumis work pre-view and all looks good!
Following up from the feedback on OTG functionalities provided by BMS on 8-6-22.
As a user, I need to be able to select/sort studies with summary stats even before clicking on the "gene prioritisation" tab. This will allow a better user experience with quicker navigation through the data. This should be a straightforward task.
Tasks
[] Add the sumstats info (yes/no) next to each study.
Specifications:
1) On the Target/gene page: add this next to each row in the L2G table and the coloc table (see example below)
2) On the Variant page: add this in the tables (see example below)
3) On the gene prioritisation page: add this in the ‘Association Summary’ section, under "study details" (see example below)
Acceptance tests
How do we know the task is complete?