1

I am now in a project using a taxi GPS data(latitude and longitude ) to locate the road segment it is being on.I have the road map data. So, I wonder if I can use arcgis server to get the road segment information according to the GPS data?I wander if there is an java api for me to call easily? for Example, I have the latitude 16.34211,longitude 4.0102,I call the function getRoadSegment(16.34211,4.0102),the function then return the road segment (maybe the startpoint(x1,y1) and the endpoint(x2,y2)) this point is in.!enter image description here

This picture is when I import mxc data file into ArcGIS.

1

2 Answers 2

1

It is likely that many of the GPS points will not be exactly on the road network segments, so you will probably want to look for the best match. Once you have the segment information you can get the midpoint, start and end coordinates. Since you have ArcInfo you can use the Near analysis tool (http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//00080000001q000000).

This should add the ID numbers of the nearest feature, you can then do an attribute join to get the segments geographic information. you may want to check your results for their vertical coordinates (assuming you have that in the GPS data), so that you are correctly assigning in the cases of overpasses and other locations where the vertical topology is an issue.

2
  • Another question please, if I get the ID numbers of the nearest feature ,how can I find the street number(not a building ,just the street it is located )?Is it possible ? Or ,can you tell me if these exists other more simpel tools for me to do reverse geocoding?
    – VicoWu110
    Commented Oct 19, 2013 at 3:07
  • Once you have the nearest street id numbers you can do an attribute join or relate between you GPS points and the streets. This will give your GPS points access to any information that the streets have.
    – Hotpepper
    Commented Oct 19, 2013 at 14:31
1

Mapperz is correct that you would have to publish a geocoding service in order for ArcGIS Server to help with this. the specific operation which allows you to turn XY points into addresses is called 'reverse geocoding'

http://resources.arcgis.com/en/help/arcgis-rest-api/index.html#/Reverse_Geocode/02r3000000r5000000/

Hotpepper is correct that not all GPS points fall directly on road networks, in order to control the search tolerance when reverse geocoding, the distance parameter controls how far away to look.

if you really trying to utilize the Esri JavaScript API (as your tag implies), please check out esri.tasks.locator.locationToAddress()

API Reference https://developers.arcgis.com/en/javascript/jsapi/locator-amd.html#locationtoaddress Sample https://developers.arcgis.com/en/javascript/jssamples/locator_reverse.html

2
  • Thank you.I am sure that every GPS point it get will definitely be an point located in an road.So ,maybe search tolerance will be unnecessary.
    – VicoWu110
    Commented Oct 18, 2013 at 11:34
  • ,I don't want javascript, I just want to use this feature in my java application ,not a web application , So ,is there any api for my java application?I don't know if arcGIS server for java platform will meet my requirement.
    – VicoWu110
    Commented Oct 19, 2013 at 3:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.