I want to export the values of NDVI and NDBI for the feature collection.
var data= L8TOA1.filterDate('2019-02-01', '2019-03-28')
.filter(ee.Filter.equals('WRS_PATH', 146))
.filter(ee.Filter.eq('WRS_ROW', 40))
.sort('CLOUD_COVER').first();
print(data);
//Get cloud cover information
var cloud= data.get('CLOUD_COVER');
print('cloud_cover is',cloud);
//Cip with boundary
var Study_region = data.clipToCollection(aoi);
// Define the visualization parameters.
var colour = {bands: ['B5', 'B4', 'B3'],min: 0,max: 0.5,gamma: 1.4,}
// Add layer to the map
Map.addLayer(Study_region,colour,'FCC');
Map.centerObject(aoi, 9);
//Indice
var NDBI = ee.Image (Study_region.normalizedDifference(['B6', 'B5']).rename('NDBI'));
var NDVI = ee.Image (Study_region.normalizedDifference(['B5', 'B4']).rename('NDVI'));
var SI= NDBI.addBands(NDVI)
print("Stacked_Image",SI);
var viz = [
'#FFFFFF','#808080','#000000','#FF0000', '#800000', '#FFFF00', '#008000', '#00FFFF', '#0000FF', '#FF00FF', '#800080'];
Map.addLayer(NDBI, {min: -1, max: 1, palette: viz},'NDBI');
// Get the Indices values to the point
var VTP = ee.FeatureCollection(SI.select(['NDBI','NDVI'])
.reduceRegion({
reducer: ee.Reducer.mean(),
geometry: Urban.geometry(),
scale: 30
}));
var Urban = Urban.set(VTP) ;
print('a',Urban);
print("Indices values to the point",VTP);
Export.table.toDrive({
collection: Urban,
description :"Indcies",
folder:"GEE",
fileNamePrefix: "Indcies",
fileFormat:"CSV",
selectors:['NDBI','NDVI']
});
When I exported the data, the value of NDBI and NDVI are not exported. Only the names were there exported.