Always a fan of simple, effective utilities, I couldn’t pass up selecting this useful little function. I discovered it while searching for code that would provide the altitude of any location on the Earth’s surface. My specific use case related to some satellite ground station analysis I was conducting, but I can see lots of other reasons why it would be useful to have elevation data. Lo and behold, this function is exactly what I needed!
Jaroslaw derives his solution from Google Maps and its API web service. The website is queried, the URL is parsed, and the elevation extracted. The other thing I like about this submission is the quality of the craftsmanship. The code provides clear, concise help documentation. It works with scalar and vector latitude/longitude pairs. It has robust and helpful error handling. Well done!
I drove this afternoon from southern Virginia to central Maryland. Thanks to this submission, I now know that I am 114.3 meters farther from sea level than I was this morning. What fun facts might you uncover?
Comments are closed.