epam/NGB

Visualize set of drugs associated with a target using TMAP algorithm

mzueva opened this issue · 0 comments

mzueva commented

Background
In order to explore the drugs associated with a target we can use TMAP algorithm to plot drugs bases on their chemical structure (SMILES).

Approach

Plot generation
  • API shall provide an API method to generate TMAP plot for a list of selected genes
  • API shall fetch SMILES structure for all the drugs associated with specified genes and generate a csv file containing: gene name, gene id, drug name, drug id, smiles.
  • API shall execute python script to generate html report based on the csv with drug structures and place generated static resources (html, js) into static resources folder.
    • Path to python script shall be specified in properties
    • Path to folder specified in properties, e.g. '/opt/ngb/static/', + gene ids, e.g. resulting folder shall look like '/opt/ngb/static/ENS0001-ENS0002-ENS0003/', this path shall be also passed as argument to python script
    • Overall command shall look like python tmap.py --drugs /opt/ngb/tmp/drugs.csv --output /opt/ngb/static/ENS0001-ENS0002-ENS0003/.
    • Method shall return that static resources were generated successfully (script exited with 0 code and folder is not empty), gene part of generated path ENS0001-ENS0002-ENS0003 shall be returned as result
    • Before execution API shall check, if static folder already contains report for selected combination of genes, it shall be returned without script execution
Visualisation
  • Add button TMAP plot to the drugs panel
    image
  • API method will return path to generated static report, e.g. 'ENS0001-ENS0002-ENS0003', GUI shall show a throbber while waiting for response, then display a link to $ngb_root/ENS0001-ENS0002-ENS0003/ (similar as it is done for Miew full screen view for example)

Other options
A clear and concise description of any alternative solutions or features you've considered.