I have a dataframe consisting of three columns, "Point_name" "longitude" and "latitude"
Point_Name Longitude Latitude
University of Arkansas 36.067832 -94.173655
Lehigh University 40.601458 -75.360063
Harvard University 42.379393 -71.115897
Is there an R package I can use to calculate distances between each point? The aim is to get R to "measure" the distance between points and then produce either a dataframe of points that have another point within "X" (eg. 500 meters) distance radius or produce a dataframe like this one...
Point_Name Longitude Latitude Nearest_Point Distance_km
University of Arkansas 36.067832 -94.173655 Lehigh University 1750
Lehigh University 40.601458 -75.360063 Harvard University 450
Harvard University 42.379393 -71.115897 Lehigh University 450