scout/adapter/mongo/hgnc.py
def ensembl_genes(self, build='37'):
        """Return a dictionary with ensembl ids as keys and gene objects as value.

        Args:
            build(str)
        
        Returns:
            genes(dict): {<ensg_id>: gene_obj, ...}
        """
        genes = {}
        
        LOG.info("Fetching all genes")
        for gene_obj in self.hgnc_collection.find({'build':build}):
            ensg_id = gene_obj['ensembl_id']
            hgnc_id = gene_obj['hgnc_id']
            
            genes[ensg_id] = gene_obj
        
        LOG.info("Ensembl genes fetched")

        return genes
def ensembl_genes(self, build='37'):
        genes = {}
        
        LOG.info("Fetching all genes")
        for gene_obj in self.hgnc_collection.find({'build':build}):
            ensg_id = gene_obj['ensembl_id']
            hgnc_id = gene_obj['hgnc_id']
            
            genes[ensg_id] = gene_obj
        
        LOG.info("Ensembl genes fetched")

        return genes
def ensembl_genes ( self , build = '37' ) : genes = { } LOG . info ( "Fetching all genes" ) for gene_obj in self . hgnc_collection . find ( { 'build' : build } ) : ensg_id = gene_obj [ 'ensembl_id' ] hgnc_id = gene_obj [ 'hgnc_id' ] genes [ ensg_id ] = gene_obj LOG . info ( "Ensembl genes fetched" ) return genes
Return a dictionary with ensembl ids as keys and gene objects as value.

        Args:
            build(str)
        
        Returns:
            genes(dict): {<ensg_id>: gene_obj, ...}
Return a dictionary with ensembl ids as keys and gene objects as value .