index.d.ts 1.2 KB

12345678910111213141516171819202122
  1. import { FeatureCollection, Point, GeoJsonProperties, MultiPolygon } from 'geojson';
  2. /**
  3. * Takes a square or rectangular grid {@link FeatureCollection} of {@link Point} features with z-values and an array of
  4. * value breaks and generates filled contour isobands.
  5. *
  6. * @function
  7. * @param {FeatureCollection<Point>} pointGrid input points - must be square or rectangular
  8. * @param {Array<number>} breaks where to draw contours
  9. * @param {Object} [options={}] options on output
  10. * @param {string} [options.zProperty='elevation'] the property name in `points` from which z-values will be pulled
  11. * @param {Object} [options.commonProperties={}] GeoJSON properties passed to ALL isobands
  12. * @param {Array<Object>} [options.breaksProperties=[]] GeoJSON properties passed, in order, to the correspondent isoband (order defined by breaks)
  13. * @returns {FeatureCollection<MultiPolygon>} a FeatureCollection of {@link MultiPolygon} features representing isobands
  14. */
  15. declare function isobands(pointGrid: FeatureCollection<Point>, breaks: number[], options?: {
  16. zProperty?: string;
  17. commonProperties?: GeoJsonProperties;
  18. breaksProperties?: GeoJsonProperties[];
  19. }): FeatureCollection<MultiPolygon>;
  20. export { isobands as default, isobands };