google_speedLimits | R Documentation |
Returns the posted speed limit for a given road segment. In the case of road segments with variable speed limits, the default speed limit for the segment is returned. The speed limits service is only available to Google Maps API Premium Plan customers with an Asset Tracking license.
google_speedLimits(
df_path = NULL,
lat = NULL,
lon = NULL,
placeIds = NULL,
units = c("KPH", "MPH"),
simplify = TRUE,
curl_proxy = NULL,
key = get_api_key("roads")
)
df_path |
|
lat |
string specifying the latitude column |
lon |
string specifying the longitude column |
placeIds |
vector of Place IDs of the road segments. Place IDs are returned in response to google_snapToRoads and google_nearestRoads reqeusts. You can pass up to 100 placeIds at a time |
units |
Whether to return speed limits in kilometers or miles per hour |
simplify |
|
curl_proxy |
a curl proxy object |
key |
|
The accuracy of speed limit data returned by Google Maps Roads API can not be guaranteed. The speed limit data provided is not real-time, and may be estimated, inaccurate, incomplete, and / or outdated.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.