serratus-bio / serratus.io

Front-end code for Serratus project website
https://serratus.io
GNU Affero General Public License v3.0
11 stars 11 forks source link

RdRp Geo map - Organism pull down menu #219

Closed ababaian closed 1 year ago

ababaian commented 1 year ago

The beta page for RdRp Geo Map (https://serratus.io/geo) with code components in https://github.com/serratus-bio/serratus.io/tree/main/src/components/Geo is a bit spartan.

The underlying data which the MapPlot.tsx function plots is stored in rdrp_pos.tsv and you can see the columns available here:

un_id   biosample_id    release_date    tax_id  scientific_name coordinate_x    coordinate_y    from_text
DRR021448   SAMD00018415    2015-07-14 10:38:15 "318829"    Pyricularia oryzae  -53.073466889   -10.769946429   brazil
DRR022241   SAMD00018962    2015-02-17 09:27:39 "565456"    Thujopsis dolabrata var. hondae 140.74741987    40.82222627 japan:aomori
DRR022329   SAMD00019235    2018-01-09 20:09:36 "941566"    Enkianthus perulatus    134.22217792    35.49441833 japan: tottori
DRR022330   SAMD00019235    2018-01-09 20:09:37 "941566"    Enkianthus perulatus    134.22217792    35.49441833 japan: tottori
DRR023219   SAMD00019539    2014-12-04 10:09:40 "79674" Macrobrachium rosenbergii   85.85766    20.18689    india: odisha, bhubaneswar, central institute of freshwater aquaculture
DRR023776   SAMD00020837    2015-02-14 09:39:34 "458240"    Arum concinnatum    25.14238    35.34194    greece: crete island
DRR024737   SAMD00022880    2015-11-24 10:21:11 "6161"  Dugesia japonica    137.04074133    35.752191505    japan:gifu, gujo, iruma river
DRR024738   SAMD00022878    2015-11-24 10:21:11 "6161"  Dugesia japonica    137.04074133    35.752191505    japan:gifu, gujo, iruma river
DRR029067   SAMD00024755    2015-01-26 10:28:37 "64793" Wasmannia auropunctata  -52.97901   5.067   
DRR029069   SAMD00024757    2015-01-26 10:28:36 "64793" Wasmannia auropunctata  -52.97901   5.067   
...

Task 1:

Add a pull-down menu below the world map which contains a unique list of all scientific_name in the rdrp_pos.tsv file. Once a specific organism is selected such as Homo sapien, the world map above should refresh / redraw and display on the map only those points which match Homo sapien.

Pull down menu should visually match the pull-down menu in the RdRp Explorer page (https://serratus.io/explorer/rdrp)

ababaian commented 1 year ago

Example Layout: Screenshot from 2023-01-18 12-51-04

lukepereira commented 1 year ago

I'll work on cleaning up the previous PRs and getting them merged/deployed in main