Bio.Align.bigpsl 模組
Bio.Align 支援 bigPsl 格式的比對檔案。
bigPsl 檔案是一種 bigBed 檔案,具有 BED12+13 格式,包含 12 個預定義的 BED 欄位和在 autoSql 檔案 bigPsl.as 中定義的 13 個自訂欄位。此模組使用 Bio.Align.bigbed 模組來解析檔案,但以 bigPsl.as 中定義的 PSL 相容方式儲存資料。由於 bigPsl 格式是 bigBed 格式的特殊情況,bigPsl 檔案是二進制的,並以 bigBed 檔案的方式進行索引。
有關更多資訊,請參閱 http://genome.ucsc.edu/goldenPath/help/bigPsl.html。
您應該透過 Bio.Align 函數使用此模組。
- class Bio.Align.bigpsl.AlignmentWriter(target, targets=None, compress=True, extraIndex=(), cds=False, fa=False, mask=None, wildcard='N')
基底類別:
AlignmentWriter
bigPsl 檔案格式的比對檔案寫入器。
- fmt: str | None = 'bigPsl'
- __init__(target, targets=None, compress=True, extraIndex=(), cds=False, fa=False, mask=None, wildcard='N')
建立一個 AlignmentWriter 物件。
- 引數
target - 輸出串流或檔案名稱。
- targets - 一個 SeqRecord 物件的列表,其中包含染色體,其
順序與比對中出現的順序相同。每個 SeqRecord 中的序列內容可能未定義,但必須定義序列長度,如以下範例所示
SeqRecord(Seq(None, length=248956422), id=”chr1”)
如果 targets 為 None(預設值),則比對必須具有一個屬性 .targets,該屬性提供 SeqRecord 物件的列表。
- compress - 如果為 True(預設值),則使用 zlib 壓縮資料。
如果為 False,則不壓縮資料。
- extraIndex - 包含要編入索引的額外欄位名稱的字串列表。
預設值為空列表。
- cds - 如果為 True,則尋找 CDS 類型的查詢特徵並寫入
到 PSL 檔案中(預設值:False)。
- fa - 如果為 True,則將查詢序列包含在 PSL 檔案中
(預設值:False)。
- mask - 指定是否遮蔽目標序列中的重複區域,
並應在 repMatches 欄位中報告,而不是在 matches 欄位中報告。可接受的值為 None:不遮蔽(預設值);“lower”:使用小寫字元遮蔽;“upper”:使用大寫字元遮蔽。
- wildcard - 在目標或查詢序列中將與萬用字元的比對報告
在 nCount 欄位中,而不是在 matches、misMatches 或 repMatches 欄位中。預設值為 ‘N’。
- write_file(stream, alignments)
寫入檔案。
- __abstractmethods__ = frozenset({})
- class Bio.Align.bigpsl.AlignmentIterator(source)
基底類別:
AlignmentIterator
bigPsl 檔案的比對迭代器。
載入並以遞增方式傳回儲存在 bigPsl 檔案中的成對比對。額外的比對資訊儲存為每個比對的屬性。
- fmt: str | None = 'bigPsl'
- __abstractmethods__ = frozenset({})