Skip to contents

This function checks if your R session currently have Wifi or Internet connection.

Usage

haveInternet(thresh = 3, url = "http://www.google.com")

Arguments

thresh

Numeric. How many seconds to consider a slow connection?

url

Character. URL to test the readLines 1 command

Value

Boolean. Result of checking if device has internet connection.