Statistical API Reference
Submit statistical request
Authorizations:
Request Body schema:
required | object (ProcessRequestInput) |
required | object (StatisticalRequestAggregation) Specifies how data is aggregated and processed before statistics is calculated. |
object (StatisticalRequestCalculations) Define which statistics and histogram to calculate. It can be specified differently for each evalscript output. If omitted only the basic statistic (min, max, mean, stDev) will be calculated. |
Responses
Request samples
- Payload
{- "input": {
- "bounds": {
- "bbox": [
- 13.822174072265625,
- 45.85080395917834,
- 14.55963134765625,
- 46.29191774991382
], - "geometry": {
- "type": "Polygon",
- "coordinates": [
- [
- [
- 14.000701904296873,
- 46.23685258143992
], - [
- 13.822174072265625,
- 46.09037664604301
], - [
- 14.113311767578125,
- 45.85080395917834
], - [
- 14.55963134765625,
- 46.038922598236
], - [
- 14.441528320312498,
- 46.28717293114449
], - [
- 14.17236328125,
- 46.29191774991382
], - [
- 14.000701904296873,
- 46.23685258143992
]
]
]
},
}, - "data": [
- {
- "type": "sentinel-2-l1c",
- "id": "string",
- "dataFilter": {
- "timeRange": {
- "from": "2018-10-01T00:00:00.000Z",
- "to": "2018-11-01T00:00:00.000Z"
}, - "mosaickingOrder": "mostRecent",
- "maxCloudCoverage": 100,
- "previewMode": "DETAIL"
}, - "processing": {
- "upsampling": "NEAREST",
- "downsampling": "NEAREST",
- "harmonizeValues": true
}
}
]
}, - "aggregation": {
- "timeRange": {
- "from": "2019-08-24T14:15:22Z",
- "to": "2019-08-24T14:15:22Z"
}, - "aggregationInterval": {
- "of": "string",
- "lastIntervalBehavior": "SKIP"
}, - "width": 512,
- "height": 512,
- "resx": 0.1,
- "resy": 0.1,
- "evalscript": "string"
}, - "calculations": {
- "output name1": {
- "histograms": {
- "band name1": {
- "nBins": 0,
- "binWidth": 0,
- "lowEdge": 0,
- "highEdge": 0,
- "bins": [
- 0
]
}, - "band name2": {
- "nBins": 0,
- "binWidth": 0,
- "lowEdge": 0,
- "highEdge": 0,
- "bins": [
- 0
]
}
}, - "statistics": {
- "band name1": {
- "percentiles": {
- "k": [
- 1
]
}
}, - "band name2": {
- "percentiles": {
- "k": [
- 1
]
}
}
}
}, - "output name2": {
- "histograms": {
- "band name1": {
- "nBins": 0,
- "binWidth": 0,
- "lowEdge": 0,
- "highEdge": 0,
- "bins": [
- 0
]
}, - "band name2": {
- "nBins": 0,
- "binWidth": 0,
- "lowEdge": 0,
- "highEdge": 0,
- "bins": [
- 0
]
}
}, - "statistics": {
- "band name1": {
- "percentiles": {
- "k": [
- 1
]
}
}, - "band name2": {
- "percentiles": {
- "k": [
- 1
]
}
}
}
}
}
}Response samples
- 200
- 400
{- "data": [
- {
- "interval": {
- "from": "2019-08-24T14:15:22Z",
- "to": "2019-08-24T14:15:22Z"
}, - "outputs": {
- "output name1": {
- "bands": {
- "band name1": {
- "histogram": {
- "overflow": 0,
- "underflow": 0,
- "bins": [
- {
- "lowEdge": null,
- "highEdge": null,
- "count": null
}
]
}, - "stats": {
- "min": 0,
- "max": 0,
- "mean": 0,
- "stDev": 0,
- "sampleCount": 0,
- "noDataCount": 0,
- "percentiles": {
- "percentile [0,1]1": 0.1,
- "percentile [0,1]2": 0.1
}
}
}, - "band name2": {
- "histogram": {
- "overflow": 0,
- "underflow": 0,
- "bins": [
- {
- "lowEdge": null,
- "highEdge": null,
- "count": null
}
]
}, - "stats": {
- "min": 0,
- "max": 0,
- "mean": 0,
- "stDev": 0,
- "sampleCount": 0,
- "noDataCount": 0,
- "percentiles": {
- "percentile [0,1]1": 0.1,
- "percentile [0,1]2": 0.1
}
}
}
}
}, - "output name2": {
- "bands": {
- "band name1": {
- "histogram": {
- "overflow": 0,
- "underflow": 0,
- "bins": [
- {
- "lowEdge": null,
- "highEdge": null,
- "count": null
}
]
}, - "stats": {
- "min": 0,
- "max": 0,
- "mean": 0,
- "stDev": 0,
- "sampleCount": 0,
- "noDataCount": 0,
- "percentiles": {
- "percentile [0,1]1": 0.1,
- "percentile [0,1]2": 0.1
}
}
}, - "band name2": {
- "histogram": {
- "overflow": 0,
- "underflow": 0,
- "bins": [
- {
- "lowEdge": null,
- "highEdge": null,
- "count": null
}
]
}, - "stats": {
- "min": 0,
- "max": 0,
- "mean": 0,
- "stDev": 0,
- "sampleCount": 0,
- "noDataCount": 0,
- "percentiles": {
- "percentile [0,1]1": 0.1,
- "percentile [0,1]2": 0.1
}
}
}
}
}
}, - "error": {
- "type": "BAD_REQUEST"
}
}
]
}:::
Submit statistical request
Authorizations:
Request Body schema:
required | object (ProcessRequestInput) |
required | object (StatisticalRequestAggregation) Specifies how data is aggregated and processed before statistics is calculated. |
object (StatisticalRequestCalculations) Define which statistics and histogram to calculate. It can be specified differently for each evalscript output. If omitted only the basic statistic (min, max, mean, stDev) will be calculated. |
Responses
Request samples
- Payload
{- "input": {
- "bounds": {
- "bbox": [
- 13.822174072265625,
- 45.85080395917834,
- 14.55963134765625,
- 46.29191774991382
], - "geometry": {
- "type": "Polygon",
- "coordinates": [
- [
- [
- 14.000701904296873,
- 46.23685258143992
], - [
- 13.822174072265625,
- 46.09037664604301
], - [
- 14.113311767578125,
- 45.85080395917834
], - [
- 14.55963134765625,
- 46.038922598236
], - [
- 14.441528320312498,
- 46.28717293114449
], - [
- 14.17236328125,
- 46.29191774991382
], - [
- 14.000701904296873,
- 46.23685258143992
]
]
]
},
}, - "data": [
- {
- "type": "sentinel-2-l1c",
- "id": "string",
- "dataFilter": {
- "timeRange": {
- "from": "2018-10-01T00:00:00.000Z",
- "to": "2018-11-01T00:00:00.000Z"
}, - "mosaickingOrder": "mostRecent",
- "maxCloudCoverage": 100,
- "previewMode": "DETAIL"
}, - "processing": {
- "upsampling": "NEAREST",
- "downsampling": "NEAREST",
- "harmonizeValues": true
}
}
]
}, - "aggregation": {
- "timeRange": {
- "from": "2019-08-24T14:15:22Z",
- "to": "2019-08-24T14:15:22Z"
}, - "aggregationInterval": {
- "of": "string",
- "lastIntervalBehavior": "SKIP"
}, - "width": 512,
- "height": 512,
- "resx": 0.1,
- "resy": 0.1,
- "evalscript": "string"
}, - "calculations": {
- "output name1": {
- "histograms": {
- "band name1": {
- "nBins": 0,
- "binWidth": 0,
- "lowEdge": 0,
- "highEdge": 0,
- "bins": [
- 0
]
}, - "band name2": {
- "nBins": 0,
- "binWidth": 0,
- "lowEdge": 0,
- "highEdge": 0,
- "bins": [
- 0
]
}
}, - "statistics": {
- "band name1": {
- "percentiles": {
- "k": [
- 1
]
}
}, - "band name2": {
- "percentiles": {
- "k": [
- 1
]
}
}
}
}, - "output name2": {
- "histograms": {
- "band name1": {
- "nBins": 0,
- "binWidth": 0,
- "lowEdge": 0,
- "highEdge": 0,
- "bins": [
- 0
]
}, - "band name2": {
- "nBins": 0,
- "binWidth": 0,
- "lowEdge": 0,
- "highEdge": 0,
- "bins": [
- 0
]
}
}, - "statistics": {
- "band name1": {
- "percentiles": {
- "k": [
- 1
]
}
}, - "band name2": {
- "percentiles": {
- "k": [
- 1
]
}
}
}
}
}
}Response samples
- 200
- 400
{- "data": [
- {
- "interval": {
- "from": "2019-08-24T14:15:22Z",
- "to": "2019-08-24T14:15:22Z"
}, - "outputs": {
- "output name1": {
- "bands": {
- "band name1": {
- "histogram": {
- "overflow": 0,
- "underflow": 0,
- "bins": [
- {
- "lowEdge": null,
- "highEdge": null,
- "count": null
}
]
}, - "stats": {
- "min": 0,
- "max": 0,
- "mean": 0,
- "stDev": 0,
- "sampleCount": 0,
- "noDataCount": 0,
- "percentiles": {
- "percentile [0,1]1": 0.1,
- "percentile [0,1]2": 0.1
}
}
}, - "band name2": {
- "histogram": {
- "overflow": 0,
- "underflow": 0,
- "bins": [
- {
- "lowEdge": null,
- "highEdge": null,
- "count": null
}
]
}, - "stats": {
- "min": 0,
- "max": 0,
- "mean": 0,
- "stDev": 0,
- "sampleCount": 0,
- "noDataCount": 0,
- "percentiles": {
- "percentile [0,1]1": 0.1,
- "percentile [0,1]2": 0.1
}
}
}
}
}, - "output name2": {
- "bands": {
- "band name1": {
- "histogram": {
- "overflow": 0,
- "underflow": 0,
- "bins": [
- {
- "lowEdge": null,
- "highEdge": null,
- "count": null
}
]
}, - "stats": {
- "min": 0,
- "max": 0,
- "mean": 0,
- "stDev": 0,
- "sampleCount": 0,
- "noDataCount": 0,
- "percentiles": {
- "percentile [0,1]1": 0.1,
- "percentile [0,1]2": 0.1
}
}
}, - "band name2": {
- "histogram": {
- "overflow": 0,
- "underflow": 0,
- "bins": [
- {
- "lowEdge": null,
- "highEdge": null,
- "count": null
}
]
}, - "stats": {
- "min": 0,
- "max": 0,
- "mean": 0,
- "stDev": 0,
- "sampleCount": 0,
- "noDataCount": 0,
- "percentiles": {
- "percentile [0,1]1": 0.1,
- "percentile [0,1]2": 0.1
}
}
}
}
}
}, - "error": {
- "type": "BAD_REQUEST"
}
}
]
}