0

I have problem with the order of featurecollection. I found the order of featurecollection changed when uploading csv or exporting featurecollection to Assets, even if an ee.FeatureCollection.Sort operation is adopted.

As shown in the below figure, I hope the featurecollection is sorting by the Index column from 0 to maximum, but the uploading/export results are not ideal. enter image description here

My code is below:

var LUT = ee.FeatureCollection('users/SiJia/GEE_LUT/LUT/1_56w');

var LUT_sorted = LUT.sort('Index');

LUT_sorted=LUT_sorted.map(function(f){
  var newGeometry =ee.Geometry.Point([0, 0]);
  f=f.setGeometry(newGeometry);
  return f;
});

Export.table.toAsset({collection:LUT_sorted, 
                      description:'LUT_sorted', 
                      assetId:"GEE_LUT/1_56w_sorted"});

Do you have any suggestions?

New contributor
李思佳 is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.