https://github.com/reyemtm/elevationquery
A tool that queries publicly available elevations for a given set of points and returns the result as an array and GeoJSON.
https://github.com/reyemtm/elevationquery
elevation geojson maps usgs
Last synced: 3 months ago
JSON representation
A tool that queries publicly available elevations for a given set of points and returns the result as an array and GeoJSON.
- Host: GitHub
- URL: https://github.com/reyemtm/elevationquery
- Owner: reyemtm
- License: mit
- Created: 2021-02-17T12:32:13.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2021-06-04T20:00:16.000Z (about 4 years ago)
- Last Synced: 2025-03-10T00:04:51.955Z (4 months ago)
- Topics: elevation, geojson, maps, usgs
- Language: JavaScript
- Homepage: https://observablehq.com/@reyemtm/query-elevations-using-usgs-and-gmrt
- Size: 827 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Elevation Query
```JavaScript
import elQ from "elevation-query";
import fs from "fs";
const { getElevation, getPointArray } = elQ;const line = JSON.parse(fs.readFileSync("./docs/trail.geojson"));
const points = getPointArray(line, {max: 5});(async () => {
//Providers are USGS and GMRT (default)
const { elevationArray, featureCollection } = await getElevation(points, {provider: ""});
console.log(points);
console.log(elevationArray)
})()
```