2

I'm trying to figure out an efficient way of pulling data about ground cover along a specific path, where I know the starting lat/long and the end lat/long.

I've found that the USGS has ground cover data available in GeoTIFF files, but I'm having a hard time figuring out how I can get data from these files along a path easily. Before I go down the long road of learning about this format and trying to write something to efficiently get this data, is there a better way? Am I making a lot more work for myself?

I already get the topography along the path by using the Bing elevation API, but there doesn't seem to be any API out there I can find for ground cover. Specifically, I want to supplement the topography with a 'best guess' about tree coverage, etc, along the 2D path that I'm drawing with the Bing data.

I'm currently using a PHP backend and displaying the data using d3.js on the client side (this is for a web application) but I don't really care how the data is found, as long as I can do it in an automated way. So I'd prefer a command line tool or some kind of library for PHP/Python/Ruby/etc.

3
  • What software are you using?
    – Aaron
    Commented Jul 10, 2015 at 15:26
  • Right now, the backend is PHP and I'm rendering the elevation using d3.js, but I can pretty much use anything to get the data (as long as it runs on Linux.) This is for a web based app.
    – Anjuna
    Commented Jul 10, 2015 at 15:29
  • Please edit your question to provide these additional details because potential answerers go not always read the comments.
    – PolyGeo
    Commented Jul 10, 2015 at 20:07

1 Answer 1

1

You could try summing distances over each pair of successive points in your path (sample it if needed), taking into account the average elevation to calculate the radius in the great circle distance calculation.

See top answer there about taking elevation into account for distance between 2 points https://stackoverflow.com/questions/1108965/taking-altitude-into-account-when-calculating-geodesic-distance

edit: After thinking again, since altitude changes impact on distance may be small compared to the error due to a great circle model, use of proper geodesic model is prefered (https://en.wikipedia.org/wiki/Vincenty%27s_formulae). Another way to see it is to calculate the distance with usual methods (e.g wgs84 and pyproj) for each sub-segment and adjust it using basic geometry: length of hypothenuse of the triangle having the base length calculated

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.