samtools fastq
worked perfectly.
• 0 views
•
link
I want to get all the reads from a bam file in a single fastq file. I am getting the message "Segmentation fault (core dumped)" while running
bedtools bamtofastq -i in.name.sorted.bam -fq out.fq
However, it works for the PE mode
bedtools bamtofastq -i in.name.sorted.bam -fq out.R1.fq -fq2 out.R2.fq
Bedtools version: v2.29.0
Any suggestion would be very helpful.
an alternative would be to try
samtools fastq
the bedtools bamtofastq also recommends that:
If you want to create a single, interleaved FASTQ file for paired-end data, you can just write both to /dev/stdout:
bedtools bamtofastq -i x.bam -fq /dev/stdout -fq2 /dev/stdout > x.ilv.fq
Also, the samtools fastq command has more fucntionality and is a useful alternative.
samtools fastq
worked perfectly.
Log in to answer this question.
It might be because your directory doesn't have enough space/memory or your program is trying to write in a file that is read only.