首页 > 解决方案 > Reduce Regions, some features dont contains centroid of pixel, in consecuence extracts of min or max obtains null value

问题描述

I have some problems to extract min or max statistcs from stack image to FeatureCollection.

----var results_max = ee.Image(lc_stack).select(bandas).reduceRegions(fc ,ee.Reducer.max(),10);

Specification of problem

1 When i use min or max reducers, features which don´t contain centroid of pixel, appears like null value (Like Feature 0, ID = 2379127 ). Conversly, features that contain centroid appear with values of min and max statistics (Like Feature 0, ID = 2379128 ).

2 On the other hand, when i use mean or count reducers, statistics are obteined by proportional area, so we don't have problems with null values.

WHAT I WOULD LIKE TO OBTAIN

Main objective: Statistics of min or max, but wihout null values, i'm not interested in modify 'tileScale'

If it is impossible to do, i would like to extract mean values BUT ONLY for features which can´t obtain data for min or max. And export data like unique csv file if it's possible.

code link : https://code.earthengine.google.com/114d01347161e118818b1baf69fcf5fc

Thank you for your time, have a nice day.

标签: javascriptrastergoogle-earth-engine

解决方案


推荐阅读