1

I have a .csv that contains 200 points, with several properties. I've imported this asset as a feature collection. All of these points should be over water, but there is a margin of error (a known margin of error, if that's relevant) and some have been placed on dry land.

Is there any way I can use the drawing tools to drag these points to their proper location on the water, so I can export a .csv with these updated coordinates? I would prefer not to update their coordinates by hand in excel.

1 Answer 1

2

You can force the geometries into the drawing tools, but only their geometries, not with any associated properties.

var sampleFeatureCollection = ee.FeatureCollection([
  ee.Feature(ee.Geometry.Point(1,1), {}),
  ee.Feature(ee.Geometry.Point(2,2), {}),
  ee.Feature(ee.Geometry.Point(3,3), {})
])
  
var tools = Map.drawingTools()
tools.addLayer(sampleFeatureCollection.aggregate_array(".geo").getInfo())

Once you've edited them, you can get them back out with tools.toFeatureCollection(). Matching them back up with their original properties might be as simple as converting the original collection to list, and zipping the two, but you need to verify if order is preserved going into and out of the drawingtools widget.

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.