Last active
August 29, 2015 14:02
-
-
Save danielecook/abd4cd73097304e375b3 to your computer and use it in GitHub Desktop.
Download all of the sequence Runs for a given experiment from the sequence read archive (SRA); Requires edirect and the sra-toolkit.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function SRX_fetch_fastq() { | |
sra_set=`esearch -db sra -query $1 | efetch -format docsum | xtract -element Run@acc` | |
echo "Downloading Run $1:" | |
echo ${sra_set} | |
echo "-------" | |
for SRA in $sra_set; do | |
echo "Downloading $SRA" | |
fastq-dump $SRA | |
done; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment