コード例 #1
0
ファイル: motif.py プロジェクト: dbgoodman/splicemod
    def max_ent(self, string):
        ''' 
        score function for motifs that are found by maxent (splice acceptors
        and donors. like all score functions, returns nmers, locations, scores
        '''
        # print "Pre-score Subprocess state for {}: {}".format(self.type,self.p.poll())
        nmers, locations = util.generate_nmers(string, self.bounds)
        scores = self.call_max_ent(nmers)
        # print "Post-score Subprocess state for {}: {}".format(self.type, self.p.poll())
        # print "\tDid we get scores? {}".format(len(scores) > 0)

        
        return {'nmers': nmers, 'locations': locations, 'scores': scores}
コード例 #2
0
ファイル: feature.py プロジェクト: dbgoodman/splicemod
def generate_nmers(self, bounds):
    return util.generate_nmers(self.seq, bounds)