[R] Test internet presence

Gregor Gorjanc gregor.gorjanc at bfro.uni-lj.si
Tue Sep 12 21:25:50 CEST 2006

Prof Brian Ripley wrote:
> On Mon, 11 Sep 2006, Gregor Gorjanc wrote:
>> Prof Brian Ripley <ripley <at> stats.ox.ac.uk> writes:
>> ...
>>> Check out tests/internet.R.  nsl() checks if you can resolve host names, 
>>> which has worked well enough there.
>> Thank you prof. Ripley for this pointer. I am posting here the relevant part if
>> someone does not look at SVN. I would just like to ask why is .Platform$OS.type
>> == "unix" added to the test? Is nsl() available only on unix like platforms or
>> ... I did not found any specifics in its help page.
> Did you look at the help page on Windows?  Looking at the help page on 
> Unix only tells you about Unix.
> Hint: the help page is src/library/utils/man/unix/nsl.Rd
> (In my country, PhD students are supposed to be able to find things 
> like that out for themselves.)

Thank you for additional pointer. I did not look windows help page as I
do not have windows at disposal all the time, but You are right - I
should have looked into the sources. I found out that there is no such
function i.e. nsl() under windows.

If I summarize the thread there is (currently) no way to test for
internet presence with a general approach.

Lep pozdrav / With regards,
    Gregor Gorjanc

University of Ljubljana     PhD student
Biotechnical Faculty
Zootechnical Department     URI: http://www.bfro.uni-lj.si/MR/ggorjan
Groblje 3                   mail: gregor.gorjanc <at> bfro.uni-lj.si

SI-1230 Domzale             tel: +386 (0)1 72 17 861
Slovenia, Europe            fax: +386 (0)1 72 17 888

"One must learn by doing the thing; for though you think you know it,
 you have no certainty until you try." Sophocles ~ 450 B.C.

More information about the R-help mailing list