humann/store.py
def add(self, reference, reference_length, query, matches, bug, read_length=None): 
        """ 
        Add the hit to the list
        Add the index of the hit to the bugs list and gene list
        """
        
        # set default read length
        if read_length is None:
            read_length = 1
        
        if reference_length==0:
            reference_length=config.default_reference_length
            logger.debug("Default gene length used for alignment to gene: " + reference)
        
        # store the score instead of the number of matches
        try:
            score=math.pow(matches,config.match_power)
        except ValueError:
            logger.debug("Could not convert the number of matches to score: " +  str(matches))
            score=0.0

        # Store the scores by bug and gene
        normalized_reference_length=normalized_gene_length(reference_length, read_length)
            
        # write the information for the hit
        self.do('insert into alignment (query, bug, reference, score, length) values (?,?,?,?,?)', [query, bug, reference, score, normalized_reference_length])
 
        Add the hit to the list
        Add the index of the hit to the bugs list and gene list
        
Add the hit to the list
Add the index of the hit to the bugs list and gene list
Add the hit to the list Add the index of the hit to the bugs list and gene list
def add(self, reference, reference_length, query, matches, bug, read_length=None): 
        if read_length is None:
            read_length = 1
        if reference_length==0:
            reference_length=config.default_reference_length
            logger.debug("Default gene length used for alignment to gene: " + reference)
        try:
            score=math.pow(matches,config.match_power)
        except ValueError:
            logger.debug("Could not convert the number of matches to score: " +  str(matches))
            score=0.0
        normalized_reference_length=normalized_gene_length(reference_length, read_length)
        self.do('insert into alignment (query, bug, reference, score, length) values (?,?,?,?,?)', [query, bug, reference, score, normalized_reference_length])
def add ( self , reference , reference_length , query , matches , bug , read_length = None ) : if read_length is None : read_length = 1 if reference_length == 0 : reference_length = config . default_reference_length logger . debug ( "Default gene length used for alignment to gene: " + reference ) try : score = math . pow ( matches , config . match_power ) except ValueError : logger . debug ( "Could not convert the number of matches to score: " + str ( matches ) ) score = 0.0 normalized_reference_length = normalized_gene_length ( reference_length , read_length ) self . do ( 'insert into alignment (query, bug, reference, score, length) values (?,?,?,?,?)' , [ query , bug , reference , score , normalized_reference_length ] )
Add the hit to the list
Add the index of the hit to the bugs list and gene list
Add the hit to the list Add the index of the hit to the bugs list and gene list
""" 
        Add the hit to the list
        Add the index of the hit to the bugs list and gene list
        """ # set default read length # store the score instead of the number of matches # Store the scores by bug and gene # write the information for the hit
self
reference
reference_length
query
matches
bug
read_length