當前位置: 首頁>>代碼示例>>Python>>正文


Python Fasta.text方法代碼示例

本文整理匯總了Python中TAMO.seq.Fasta.text方法的典型用法代碼示例。如果您正苦於以下問題:Python Fasta.text方法的具體用法?Python Fasta.text怎麽用?Python Fasta.text使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在TAMO.seq.Fasta的用法示例。


在下文中一共展示了Fasta.text方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: go

# 需要導入模塊: from TAMO.seq import Fasta [as 別名]
# 或者: from TAMO.seq.Fasta import text [as 別名]
 def go(self):
     """Execution function: runs TAMO.MD.Meme.Meme and catches the output in self.output for access from MDAP."""
     import time
     
     # write a temp fasta file of coregulated seqs to use as input to Meme(file=TempFasta)
     ctimeStr  = time.ctime().replace(' ','_')
     fileName  = 'tempFastaOfCoRegSeqs.MDAP.%s.fas' %(ctimeStr)
     tFasta    = open(fileName, 'w')
     tFastaTxt = Fasta.text(self.coRegSeqs[0])
     tFasta.write(tFastaTxt)
     
     # Call TAMO to do its thing:
     self.output = Meme(file=fileName, width='', extra_args=self.extra_args, bfile=self.bfile)
     
     # delete temp file
     os.remove(fileName)
開發者ID:xguse,項目名稱:gusPyProj,代碼行數:18,代碼來源:MD_wrappers.py

示例2: map

# 需要導入模塊: from TAMO.seq import Fasta [as 別名]
# 或者: from TAMO.seq.Fasta import text [as 別名]
from TAMO.seq import Fasta
from gusPyCode.defs.bioDefs import geneList2FastaDict
from gusPyCode.defs.mosqData import promoterSeqPaths


geneList = map(lambda l: l.strip(), \
               open('/Users/biggus/Documents/James/Collaborations/Campbell/data/CCupAt4Days.gte2x.genes.txt', 'rU'))

sourceFasta = promoterSeqPaths.Aa_2000bpUp_hardMasked_shuf1

oFile = '/Users/biggus/Documents/James/Collaborations/Campbell/data/CCupAt4Days.gte2x.masked.shuffled.1.fas'





newFasta = geneList2FastaDict(geneList, sourceFasta, hardMasked=True)

newFasta = Fasta.text(newFasta)
    
oFile = open(oFile, 'w')
oFile.write(newFasta)

print 'Done'
開發者ID:xguse,項目名稱:gusPyProj,代碼行數:26,代碼來源:geneList2Fasta.py


注:本文中的TAMO.seq.Fasta.text方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。