feat(website): add new collections analysis mode to W-ASAP#1005
feat(website): add new collections analysis mode to W-ASAP#1005
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
443c9c3 to
f9c0b8a
Compare
67e6782 to
a95c44e
Compare
a95c44e to
2e14d1c
Compare
13ad73f to
0789522
Compare
0789522 to
708472a
Compare
|
While testing, I found this: returns a 500 error:
(from |
|
Thanks Fabian! Regarding the query parsing: So, I've made a mistake, by assuming I can just use any variant query as a LAPIS advanced query. They query syntax for both of them has an overlap, but not all variant queries are advanced queries, and vice versa. I spoke to Chaoran about this, and he said that we should check each variant query and if it isn't a valid advanced query (i.e. we can't use it in LAPIS) we discard it from the collection. This is of course not ideal, but by doing this, we get to use at least some of the cov-spectrum collections. This requires the LAPIS endpoint to validate queries, so we can check if a variant query is valid or not. Since there is already a TODO related to this blocking LAPIS feature, I'd for now add another TODO in the code that this is a know limitation for now, and then we can tackle both of these things once we have the LAPIS endpoint. The other thing you mentioned:
Is related to this, in that variants don't perfectly match to queries we can use. I'm only using variants from collections that are defined by a I'm not sure how many collections are defined like this, but it is expected that a lot of them won't work. That's also why we want to specifically filter for wastewater collections as a follow-up task. The specific collection you mentioned defines the variants via the lineage property on the sequences. This can't be applied to wastewater sequences, because the amplicon sequences we have are not assigned to a lineage (they are often too short to confidently assign a linage to them). -- I hadn't considered it that much before, but now I see that in its current form this feature isn't very useful. I still think it makes sense to maybe postpone the two things above to a future PR, to keep this one kind of small? This one sets up all the 'plumbing' to connect stuff together, in that way I think it's fine to have it as a separate PR. But if you disagree, I can also keep this one open and we do the LAPIS endpoint and the filtering in this PR as well. (The other stuff you've flagged I will of course fix in this PR!) |
|
Sounds good to me. Getting it fully functional can be done in later PRs, since this is only on staging for now anyway 👍 |
|
I've changed the way the staging switch works here: 23e50b0 |

resolves #1006
Summary
Add a new 'Collection' analysis mode, where you can select a cov-spectrum collection to analyze, meaning you can see the prevalence of the defined variants over time.
Specific changes:
CollectionAnalysisFiltercomponent to be used in theWasapPageStateSelector.useWasapPageDatawas extended to also fetch the collections. During this, the file was also refactored entirely.Screenshot
Screen.Recording.2026-02-05.at.10.09.52.mov
Follow-ups
The generation of the coverage queries still needs to be implemented: #1026 (there is a TODO in the code)
I left some of the refactoring for later, as it's not urgent and I didn't want to put too much into this PR: #1025
Another follow-up: We want to implement a filter for the collections that are shown: #1027
Useful links
https://github.com/GenSpectrum/cov-spectrum-server/blob/develop/docs/api.md
PR Checklist