Skip to content

Latest commit

 

History

History
33 lines (25 loc) · 1.15 KB

add_tool.md

File metadata and controls

33 lines (25 loc) · 1.15 KB

Add new fusion detection tool

NB: Please follow all the steps before submitting a PR. Make sure to submit also the test results.

  1. Implement a new tool in fusion_report/parsers/{tool_name.py}.
# Replace Test with the name of the new tool
"""Test module"""
from typing import Any, Dict, List, Tuple
from fusion_report.parsers.abstract_fusion import AbstractFusionTool

class Test(AbstractFusionTool):
    """Test tool parser."""

    def parse(self, line, delimiter='\t') -> Tuple[str, Dict[str, Any]]:
        col: List[str] = line.strip().split(delimiter) # replace delimiter if different
        fusion: str = f'{col[0]}'
        details: Dict[str, Any] = {
            'position': f'{col[2]}#{col[3]}'.replace('chr', ''),
            'score': int(col[1]),
        }

        return fusion, details
  1. Run your application on these samples: test1 and test2.
  2. Store the results in tests/test_data/
  3. Submit a pull request on GitHub.
  4. Give yourself a high five for awesome job! 👍