我正在尝试使用 bowtie2 和 samtools 将读取比对到 hg38。在获取 bam 文件并尝试为它们编制索引后,我得到了错误:
E::hts_idx_push\] Chromosome blocks not continuous \[E::sam_index\] Read 'SRR764959.25000002' with ref_name='NC_000001.11', ref_length=248956422, flags=0, pos=91387388 cannot be indexed samtools index: failed to create index for "HFFmerged.bam": No such process
对于分析此类数据的整个过程,我是一个完全的新手。我正在使用 MacBook Air 并尝试使用
fastq-dump
将一些 sra
文件转换为 fastq
,然后我使用 拆分它们
split -l 4000000 input.fastq output_prefix
并用
trim-galore
修剪它们。在将 hg38
索引为 bowtie2
之后,我使用下面的第一段代码来对齐我的读取,然后使用 sam
将我的 bam
文件转换为 samtools
。将所有 bam
文件合并在一起后,我尝试将合并的 bam
文件索引到 samtools
但出现错误:
E::hts_idx_push\] Chromosome blocks not continuous \[E::sam_index\] Read 'SRR764959.25000002' with ref_name='NC_000001.11', ref_length=248956422, flags=0, pos=91387388 cannot be indexed samtools index: failed to create index for "HFFmerged.bam
for file in /Volumes/Untitled/IPStrimmed/*.fq; do
output=$(basename "$file" .fq).sam
bowtie2 -x /Volumes/MACOS/Users/rafail/Downloads/HG38/hg38_index -U "$file" -S "/Volumes/Untitled/IPStrimmed/IPSsam/$output"
done