diff --git a/planet/planetscope/ndvi/eob.js b/planet/planetscope/ndvi/eob.js index b0491975..faa89286 100644 --- a/planet/planetscope/ndvi/eob.js +++ b/planet/planetscope/ndvi/eob.js @@ -3,7 +3,7 @@ function setup() { return { - input: ["NIR", "red", "clear", "dataMask"], + input: ["nir", "red", "clear", "dataMask"], output: [ { id: "default", bands: 4 }, { id: "index", bands: 1, sampleType: "FLOAT32" }, @@ -276,7 +276,7 @@ const colorRamp = [ let viz = new ColorRampVisualizer(colorRamp); function evaluatePixel(sample) { - let ndvi = index(sample.NIR, sample.red); + let ndvi = index(sample.nir, sample.red); const minIndex = 0; const maxIndex = 1; let visVal = null; diff --git a/planet/planetscope/ndvi/raw.js b/planet/planetscope/ndvi/raw.js index 4fb08a3a..8ebb615d 100644 --- a/planet/planetscope/ndvi/raw.js +++ b/planet/planetscope/ndvi/raw.js @@ -3,7 +3,7 @@ function setup() { return { - input: ["NIR", "red", "dataMask"], + input: ["nir", "red", "dataMask"], output: { bands: 4, }, @@ -11,5 +11,5 @@ function setup() { } function evaluatePixel(sample) { - return [index(sample.NIR, sample.red)]; + return [index(sample.nir, sample.red)]; } diff --git a/planet/planetscope/ndvi/script.js b/planet/planetscope/ndvi/script.js index e2e62a3b..e28a9a26 100644 --- a/planet/planetscope/ndvi/script.js +++ b/planet/planetscope/ndvi/script.js @@ -3,7 +3,7 @@ function setup() { return { - input: ["NIR", "red", "dataMask"], + input: ["nir", "red", "dataMask"], output: { bands: 4, }, @@ -273,7 +273,7 @@ const colorRamp = [ let viz = new ColorRampVisualizer(colorRamp); function evaluatePixel(sample) { - let ndvi = index(sample.NIR, sample.red); + let ndvi = index(sample.nir, sample.red); const minIndex = 0; const maxIndex = 1; let visVal = null;