Hi everyone
I am having trouble running the actual NDVI values eval script pasted below. Can anyone else get this script to run? The script is available here How can I get actual NDVI values? and I cannot get it to work in the ‘custom script’ part of EO Browser. I would like to be able to download a 32 bit GeoTIFF for analysis (thresholding) of the single band NDVI image (-1 to +1) in QGIS or ArcGIS.
//VERSION=3
function setup() {
return{
input: [{
bands: ["B04", "B08"]
}],
output: {
id: "default",
bands: 1,
sampleType: SampleType.FLOAT32
}
}
}
function evaluatePixel(sample) {
let ndvi = (sample.B08 - sample.B04) / (sample.B08 + sample.B04)
return [ ndvi ]
}