最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

sorting - E::hts_idx_push Chromosome blocks not continuous - Stack Overflow

programmeradmin0浏览0评论

I am aligning paired-end reads to a reference genome. I am having troubles when it comes to sorting and indexing the bam files. I have always used a bai index, however, I have learned that the genome is too large for this species and therefore a bai index won't work. Instead I am now using a csi index.

I am having multiple problems using a csi index. Originally I was getting the following error: [E::hts_idx_push] NO_COOR reads not in a single block at the end 1 -1. I fixed this by sorting the mapped and unmapped reads separately then combining them. But now I am getting the following error: [E::hts_idx_push] Chromosome blocks not continuous. I cannot figure out what is the issue. Any help would be appreciated. The code chunk I am running is below.

samtools view -b -F 4 bwa_assem_pe/$basename.bam > bwa_assem_pe/$basename.mapped.bam
samtools view -b -f 4 bwa_assem_pe/$basename.bam > bwa_assem_pe/$basename.unmapped.bam
samtools sort bwa_assem_pe/$basename.mapped.bam -o bwa_assem_pe/$basename.mapped.sorted.bam
samtools sort bwa_assem_pe/$basename.unmapped.bam -o bwa_assem_pe/$basename.unmapped.sorted.bam
samtools cat -o bwa_assem_pe/$basename.sorted.bam bwa_assem_pe/$basename.mapped.sorted.bam bwa_assem_pe/$basename.unmapped.sorted.bam
samtools index -c -m 14 bwa_assem_pe/$basename.sorted.bam

I have tried multiple fixes to no success. Advice and help would be greatly appreciated.

发布评论

评论列表(0)

  1. 暂无评论