Error downloading using SRAdb
1
0
Entering edit mode
yugi1001 • 0
@yugi1001-9936
Last seen 8.7 years ago

Hi,

 

I would appreciate some help with downloading fastq files using SRAdb. I have been facing errors for any fastq file other than the example given in the manual. The error is as below. Can someone point out what is the issue here?

Thanks

yugandhar

> if(file.exists('SRAmetadb.sqlite')) {
+   ## Not run:
+   library(SRAdb)
+   sra_dbname <- 'SRAmetadb.sqlite'
+   sra_con <- dbConnect( dbDriver("SQLite"), sra_dbname )
+   ## Download fastq files from EBI ENA through ftp
+   getFASTQfile( in_acc = c("ERR1021452"), sra_con, destDir = getwd(), srcType = 'ftp', ascpCMD = NULL )
+   
+ } else {
+   print("use getSRAdbFile() to get a copy of the SRAmetadb.sqlite file and then rerun the example")
+ }
 Show Traceback
 
 Rerun with Debug
 Error in `$<-.data.frame`(`*tmp*`, "ftp", value = "ftp://ftp.sra.ebi.ac.uk/vol1/fastq/NA/NA/NA") : 
  replacement has 1 row, data has 0 

fastq sradb ftp • 2.2k views
ADD COMMENT
0
Entering edit mode
Jack Zhu ▴ 170
@jack-zhu-3338
Last seen 7.1 years ago

Hi,

It looks ERR1021452 does not have an entry in the fastq download site:

  ftp://ftp.sra.ebi.ac.uk/vol1/fastq/ERR102

-----------------

> sraConvert (c("ERR1021452"), out_type = c("sra", "submission", "study", "sample", "experiment", "run"), sra_con)
         run submission     study    sample experiment
1 ERR1021452  ERA486171 ERP012216 ERS852165 ERX1100392

-----------------

But other fastq files can be downloaded:

>     getFASTQfile( in_acc = c("SRR000648","SRR000657"), sra_con, destDir = getwd(), srcType = 'ftp', ascpCMD = NULL )
Files are saved to:
'/Users/zhujack'

trying URL 'ftp://ftp.sra.ebi.ac.uk/vol1/fastq/SRR000/SRR000648/SRR000648.fastq.gz'
ftp data connection made, file length 84837 bytes
==================================================
downloaded 82 KB

trying URL 'ftp://ftp.sra.ebi.ac.uk/vol1/fastq/SRR000/SRR000657/SRR000657.fastq.gz'
ftp data connection made, file length 136727 bytes
==================================================
downloaded 133 KB

        run submission     study    sample experiment fastq_ID
1 SRR000648  SRA000241 SRP000098 SRS000290  SRX000122   915783
2 SRR000657  SRA000241 SRP000098 SRS000290  SRX000122   915792
                                                                     ftp
1 ftp://ftp.sra.ebi.ac.uk/vol1/fastq/SRR000/SRR000648/SRR000648.fastq.gz
2 ftp://ftp.sra.ebi.ac.uk/vol1/fastq/SRR000/SRR000657/SRR000657.fastq.gz
                               md5  bytes          audit_time       sradb_updated
1 c5e254dac864ac78d48a03e21038b110  84837 2015-03-04 11:16:50 2016-03-17 21:55:35
2 fec6ea0767b6fe661278dbd1cdfe9e43 136727 2015-03-04 11:16:50 2016-03-17 21:55:35

Hope it helps.

Jack

 

 

 

 

ADD COMMENT

Login before adding your answer.

Traffic: 860 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6