Is there a more elegant way than calling each filter in the list? It looks like ee.Filter.or wants separate arguments, not a list.
Using var NEfilter = ee.Filter.or(filterlist) gives the error:
Filter.or, argument 'filters': Invalid type. Expected: List< Filter >. Actual: List< List< Filter >>
https://code.earthengine.google.com/dffaf31424c0b5cbf2fd69187523eae0
var AllStates = ee.FeatureCollection('ft:1fRY18cjsHzDgGiJiS2nnpUU3v9JPDc2HNaR7Xk8'); // U.S. States
print (AllStates);
var NameFcn = function(name) {
return ee.Filter.eq('Name', name);
};
var NE_list = ["Massachusetts", "Connecticut", "Rhode Island", "Maine", "Vermont", "New Hampshire"];
var filterlist = NE_list.map(NameFcn)
print(filterlist)
var NEfilter = ee.Filter.or(filterlist[0],filterlist[1],filterlist[2],filterlist[3],filterlist[4],filterlist[5]);
var NEStates = AllStates.filter(NEfilter);
print(NEStates)