參考htseq-count的用法-Bluesky's blog
?? 在進行htseq前,要先將.bam文件用samtools sort一下:

sorted.bam文件進行htseq-count:

注意上下兩個命令行注釋基因格式的不同,.gtf時報錯,換成.gff時則可運行

注釋基因下載網(wǎng)址,有gtf和gff兩種格式
運行結果(感覺不太對):

上述得到的sorted和count文件已刪除
又重新samtools sort了一遍(運行的時候沒有動它 等程序自己介紹):

/mnt/d/AAA-臺式機-LY-WorkSpace/aligned$ samtools sort -n 105TRA.bam -o 105TRA_sorted-2.bam(-n說明按name sort,若不指定,則默認按染色體位置)
rseqc-count(不敢動,等程序自己結束QAQ),-s沒有設置參數(shù),默認狀態(tài):

/mnt/d/AAA-臺式機-LY-WorkSpace/aligned$ htseq-count -f bam 105TRA_sorted-2.bam gencode.v31.annotation.gff3 > 105TRA-2.count
運行結果:沒有報錯

aligned文件夾中的文件

htseq又運行一遍,-s參數(shù)設置為no:

htseq參數(shù)設置

/mnt/d/AAA-臺式機-LY-WorkSpace/aligned$ htseq-count -f bam -s no 105TRA_sorted-2.bam gencode.v31.annotation.gff3 > 105TRA-2-s-no.count
結果生成105TRA-2-s-no.count文件:

