AnsweredAssumed Answered

Appending raster properties to table format (csv or text)

Question asked by india123 on Sep 6, 2016
Latest reply on Sep 6, 2016 by india123

I having trouble to save raster statistics value into csv or text format. Below is my working code. Below code only print the raster statistics value, but i am interested to save the output value to text or csv format. 

 

I appreciate any help you can provide on the crucial bottom code. 

 

Thank you 

 

 

import arcpy
arcpy.env.workspace = r"D:\2008A"
rasterList = arcpy.ListRasters()
for raster in rasterList:
rasterObj = arcpy.Raster(raster)
print raster
bands = arcpy.GetRasterProperties_management(raster, "MEAN")
print "MEAN VALUE: %s" %bands
bands = arcpy.GetRasterProperties_management(raster, "STD")
print "STANDARD DEV: %s" %bands
bands = arcpy.GetRasterProperties_management(raster, "MINIMUM")
print "MIN VALUE: %s" %bands
bands = arcpy.GetRasterProperties_management(raster, "MAXIMUM")
print "Max VALUE: %s" %bands

Outcomes