Created
August 19, 2019 13:41
-
-
Save lakshay-arora/097197aa89903d0730f8cbca55309a53 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# calculate the distance of each data point from # (Latitude, Longitude) = (58.4442, 9.3722) | |
def calculate_distance(x): | |
return harcdist((x['LATITUDE'],x['LONGITUDE']),(58.4442, 9.3722)) | |
data['DISTANCE'] = data.progress_apply(calculate_distance,axis=1) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment