I have latitudes and longitudes that are received with 30 seconds interval. I want to display an arrow in the direction of next lat,long. can anyone help me? thanks
Show older comments
GPS trackers are sending the data, i am plotting that data on google earth. But there is no indication of the point if the person or vehicle folows the same reverse path. so i want to have a line with an arrow which shows the direction or in short a track is made.
Answers (1)
Geoff Hayes
on 25 Aug 2014
0 votes
How are you interfacing with Google Earth? What are the lines of code that you have written that plots the data on the "map"?
Since you know the previous position and the current position, I would use something like the Vincenty algorithms (or any other latitude and longitude position functions) and determine the bearing (from north) of the current position relative to the previous one. Then draw a short line that originates from the current position at an angle that is given by the bearing (from north).
Categories
Find more on Google Earth in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!