Question: unable to resolve host address 'ftp.ncbi.nlm.nih.gov'
0
gravatar for onemore100iq
3.3 years ago by
onemore100iq20
onemore100iq20 wrote:

R at the command line from ubuntu I am trying to download geo file at the command line I type R, so the command line go to

where I type download.file("http://www.ncbi.nlm.nih.gov/geo/download/?acc=GSE89413&format=file", + "gse89413.tar", + mode="wb")

but it does not work, it gave error : unable to resolve "www.ncbi.nlm.nih.gov"

and when I go to command line and type: wget ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE99nnn/GSE99xxx/suppl/GSE99xxx_RAW.tar it gave this message: unable to resolve host address 'ftp.ncbi.nlm.nih.gov'

So how to download this file in R at the command line???

any help is super highly appreciated

R • 4.9k views
ADD COMMENTlink modified 3.3 years ago • written 3.3 years ago by onemore100iq20
1

If you are getting an unable to resolve error then it sounds like you have a host name resolution problem. Is the problem general or are you only getting it with www.ncbi.nlm.nih.gov?

While not ideal you could try this IP address to see if that fixes the problem: 130.14.29.110 instead of www.ncbi.nlm.nih.gov in the URL above.

ADD REPLYlink written 3.3 years ago by GenoMax96k

Hi, Thanks for your response. But did you actually were able to open this link in your R I tried your first method: download.file(url="ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE89nnn/GSE89413/suppl/", destfile="GSE89413_2016-10-30-NBL-cell-line-STAR-fpkm.txt.gz") and did not work either, it gave me cannot open URL "ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE89nnn/GSE89413/suppl/"

ADD REPLYlink written 3.3 years ago by onemore100iq20
1

Hey, this would have been better as a comment to my answer, in order to maintain 'fluidity' of thought in the thread. Not to worry, though!

Yes, I was able to download the file in R using that exact command. From where do you run R? - a server/cluster installation? Do you have a firewall?

ADD REPLYlink written 3.3 years ago by Kevin Blighe71k

onemore100iq : Please use ADD REPLY/ADD COMMENT when responding to existing posts to keep threads logically organized.

ADD REPLYlink modified 3.3 years ago • written 3.3 years ago by GenoMax96k
0
gravatar for Kevin Blighe
3.3 years ago by
Kevin Blighe71k
Republic of Ireland
Kevin Blighe71k wrote:

I don't know about you but I cannot see the file at the location to which you're pointing. I just see the following file at: ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE89nnn/GSE89413/suppl/

  • GSE89413_2016-10-30-NBL-cell-line-STAR-fpkm.txt.gz

In R, I got this with:

download.file(url="ftp://ftp.ncbi.nlm.nih.gov/geo/series/GSE89nnn/GSE89413/suppl/", destfile="GSE89413_2016-10-30-NBL-cell-line-STAR-fpkm.txt.gz")

If you are attempting to load a GEO dataset directly into R, then you can use the GEO2R package:


There's a lot of information on how to download information from the GEO here. For downloading from the FTP site, they seem to recommended constructing the URL to access the FTP directory structure, as I have done here. By constructing a URL with http and sending 'acc' as the accession number, it just brings up a webpage that lists what information is available for that accession number, like this.

ADD COMMENTlink written 3.3 years ago by Kevin Blighe71k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1569 users visited in the last hour
_