This is a test version of Biostars. For the public version, visit https://www.biostars.org.
SRA toolkit (NCBI) - sra to fasta

Dear all,

At the moment I'm trying to download sequences from the Sequence Read Archive (SRA) from NCBI and put them into fasta format. For this I downloaded the SRA-toolkit of NCBI and used the following code:

set PATH=%PATH%;C:\Users\Admin\Desktop\sratoolkit.2.9.0-win64\sratoolkit.2.9.0-win64\bin
prefetch --max-size 100000000 SRR390728
fastq-dump C:/Users/Admin/ncbi/public/sra/SRR390728.sra

(The SRA SRR390728 is the example SRA of the toolkit, since it is relatively small in size).

The SRA is downloaded as .sra. I was wondering what I should do to turn this .sra into .fasta?

Kind regards

sratoolkit fasta sequence

You're lucky, the file is open access and available in fastq format from ENA.

1 answer

You can use the same utility fastq-dump from SRA toolkit to convert from .SAR to either .fastq or .fasta.

fastq-dump --split-files --fasta 60 SRR390728

This above command will produce two (--split-files) fasta files (--fasta) with 60 bases per line ("60" included after --fasta)

For more details - fastq-dump function help from SRA toolkit

Hi there, will it be an issue if we do not mention 60?

Can be 23 or 109, it does not matter.

Log in to answer this question.