powered by
Find central point for list of lat/long coordinates
get_centroid(lat, lng, coord.unit = c("degrees", "radians"))
A quoted string indicating what named value in the bounding box represents latitude. If NULL, will be inferred from bounding box names.
A quoted string indicating what named value in the bounding box represents longitude. If NULL, will be inferred from bounding box names.
The unit latitude and longitude are stored in.
# NOT RUN { df <- data.frame( lat = c(44.05771, 44.18475), lng = c(-73.99212, -73.81515) ) get_centroid(df$lat, df$lng) # }
Run the code above in your browser using DataLab