001、命令
samtools flagstat sample_name.sorted.bam > sample_name.flagstat.txt
a、生成的文件是一个包含16行的文本文件:
002、
(base) [b20223040323@admin2 workdir]$ cat Asiatic1.flagstat.txt ## 查看统计结果 622520785 + 0 in total (QC-passed reads + QC-failed reads) 620876200 + 0 primary 1644585 + 0 secondary 0 + 0 supplementary 0 + 0 duplicates 0 + 0 primary duplicates 621864067 + 0 mapped (99.89% : N/A) 620219482 + 0 primary mapped (99.89% : N/A) 620876200 + 0 paired in sequencing 310438100 + 0 read1 310438100 + 0 read2 612737342 + 0 properly paired (98.69% : N/A) 620022610 + 0 with itself and mate mapped 196872 + 0 singletons (0.03% : N/A) 5577184 + 0 with mate mapped to a different chr 2767972 + 0 with mate mapped to a different chr (mapQ>=5)
。
003、