I downloaded a dataset in the BAM Format from GEO using the command:
prefetch SRR13558458
It generates a file names "SRR13558458.sra".
I would like to view this file using samtools. But it seems this sra file which is a bam file is not readable using samtools view command!
First I tried to chage the sra file to bam using the following command:
sam-dump --output-file SRR13558458.bam SRR13558458
sam-dump generates an empty file!
Besides, when I change the file extension:
mv SRR13558458.sra SRR13558458.bam
samtools view SRR13558458.bam | less
I got this error:
[E::hts_hopen] Failed to open file SRR13558458.bam [E::hts_open_format] Failed to open file "SRR13558458.bam" : Exec format error samtools view: failed to open "SRR13558458.bam" for reading: Exec format error
Does anyone know how to solve this problem? Thanks!