Questions tagged [driving-distance]

24 questions
29
votes
5 answers

How to get total driving distance with Google Maps API V3?

I used to be able to get it like this: directionsService.route(directionsRequest, function(directionsResult, directionsStatus) { var directionsRenderer = new google.maps.DirectionsRenderer({ directions: directionsResult, map:…
mpen
  • 272,448
  • 266
  • 850
  • 1,236
15
votes
5 answers

Getting driving distance between two points (lat, lon) using R and Google Map API

I am trying to get the driving distance between two points with lat/lon given. I can manually put them into google map and get the driving distance but I want to do all this programatically. I guess JavaScript is the language to go. But, I do not…
Stat-R
  • 5,040
  • 8
  • 42
  • 68
7
votes
2 answers

How to find path and distance between two coordinates using OSM and python?

I need to get the driving time and distance between two sets of coordinates using Python and an open source mapping service ( preferably OSM). I found a lot of different python libraries that can calculate the distance between two given points…
M.T
  • 105
  • 1
  • 7
5
votes
1 answer

How to get the driving distance between two geographical coordinates using python?

I want to get the driving distance between two points in python. I am not allowed to use Google Maps API. Are there any open source APIs that help to calculate the driving distance between two points? If yes, a small example is Python will be…
4
votes
1 answer

Calculate driving distance locally, without Google Maps API

I need to calculate a lot of driving distances, because I am running a genetic algorithm that calculates the best route given some latitude and longitude coordinates. Currently, it is using the Haversine formula, but it is not sufficient to produce…
4
votes
2 answers

How do I get driving time from Google Maps API?

I use the following function to estimate the time (in hours) to drive a certain distance, assuming an average speed of 65 km/h: distHoras <- function(origin, destination){ xml.url <-…
Waldir Leoncio
  • 10,853
  • 19
  • 77
  • 107
3
votes
1 answer

Is there any way to determine the driving time between two locations using Apple's Maps API?

I am evaluating using google's Distance Matrix / Places / Maps API, versus Apple's Maps api for an iOS app. I am looking at the MKDirectionsRequest class, and I can't seem to find a way to determine what the driving time is between the two points.…
wfbarksdale
  • 7,498
  • 15
  • 65
  • 88
3
votes
1 answer

Driving distance between two coordinates

I have a long list of locations in excel format and I need to calculate driving distance between these locations using lat&long. Is there any macro I can use. Cheers
kolis29
  • 115
  • 2
  • 3
  • 11
2
votes
1 answer

Calculating walking time and driving time from dataset coordinates (British National Grid:Eastling&Northling)?

I am trying to find a way to get the travel time for both walking and driving for my dataset. Using ArcGIS I was able to get the liner/planar line that connects them but I do not know how to get the travel times. After days spent trying, I am…
Alexvtrix
  • 21
  • 2
2
votes
0 answers

How to calculate driving distance in iphone app by calling javascript function

I'd like to calculate the driving distance in my iphone app, no matter whether the map is displayed or not. Previously, I saw some javascript that can do the work. Here is the source code for the javascript in html:
1
vote
0 answers

Python and openrouteservice - Driving distance between 2 geolocations (not all exactly are reachable driving)

My goal is to get the driving distance/time between 2 geolocations (latitude and longitude), doing this for a file of around 2k pairs of geolocations. I must be use free APIs or whatever free resources, reason why I'm usin openrouteservice with this…
1
vote
1 answer

R gmapsdistance XML Error

I am using gmapsdistance in a for loop to get the drive time for a list of addresses. Below is the R code: for( i in 1: nrow(data_subset)){ if( i!= nrow(data_subset)){ print(i) drive_time <-…
Diablo
  • 35
  • 5
1
vote
0 answers

Google Maps API driving time

I have a question about driving time between two points extracted from the Google Maps API. Is the total driving time that we get from the response (json file) time-dependent? or it is the same for different departure times during the day?
1
vote
0 answers

Distance API for big volume of data

I'm looking into getting the driving distance between a current address (entered by a user) and the locations of some shops in the city / town of the user. The list of shops locations could get really big, up to thousands. Do you have any idea what…
Alina
  • 121
  • 9
1
vote
1 answer

How to calculate the driving distance between two points?

In my app I am getting the latitude , longitude co-ordinates of places using GeocodeService now I want to get distance between these places. I've tried GetDistanceTo method to get the distance two location co-ordinates but it gives me stright…
sunny
  • 479
  • 1
  • 9
  • 18
1
2