Example #1
0
 def gene_pathway_parse(cls, *args, **kwargs):
     stage_output_file = cls._get_stage_output_file(*args, **kwargs)
     download_files = cls._get_download_file(*args, **kwargs)
     section = kwargs['section']
     config = None
     if 'config' in kwargs:
         config = kwargs['config']
     GenePathways.gene_pathway_parse(download_files, stage_output_file, section, config=config)
Example #2
0
    def test__get_pathway_source(self):
        '''Test if the right source name is returned given a download file '''
        download_file_kegg = '/dunwich/scratch/prem/tmp/download/DOWNLOAD/MSIGDB/c2.cp.kegg.v5.0.entrez.gmt'
        source = GenePathways._get_pathway_source(download_file_kegg)
        self.assertTrue(source == "kegg", "Got back kegg as source")

        download_file_reactome = '/dunwich/scratch/prem/tmp/download/DOWNLOAD/MSIGDB/c2.cp.reactome.v5.0.entrez.gmt'
        source = GenePathways._get_pathway_source(download_file_reactome)
        self.assertTrue(source == "reactome", "Got back reactome as source")

        download_file_biocarta = '/dunwich/scratch/prem/tmp/download/DOWNLOAD/MSIGDB/c2.cp.biocarta.v5.0.entrez.gmt'
        source = GenePathways._get_pathway_source(download_file_biocarta)
        self.assertTrue(source == "biocarta", "Got back biocarta as source")

        download_file_go = '/dunwich/scratch/prem/tmp/download/DOWNLOAD/MSIGDB/c5.all.v5.0.entrez.gmt'
        source = GenePathways._get_pathway_source(download_file_go)
        self.assertTrue(source == "GO", "Got back go as source")
 def gene_pathway_parse(cls, *args, **kwargs):
     stage_output_file = cls._get_stage_output_file(*args, **kwargs)
     download_files = cls._get_download_file(*args, **kwargs)
     section = kwargs['section']
     GenePathways.gene_pathway_parse(download_files, stage_output_file, section)