| 
    
    DATA MINING
     Desktop Survival Guide by Graham Williams  | 
    
    
     
     | 
    |||
You can check whether you have access to an Internet connection using
the nsl function, checking for a specific hostname:
> nsl("www.r-project.org")
[1] "137.208.57.37"
> if(is.null(suppressWarnings(nsl("www.r-project.org")))) print("Connected?")
 |