Skip to main content

Hi,

I have set of coordinates for a polygon in CSV format, I need to create the polygon from the coordinate in FME. Kindly let me know which transformer I have to use.

Regards

K.Jayakumar

Have a look at the GeometryReplacer transformer.

If you can format the coordinates (usually as WKT) you can create the polygon using that transformer.


Here's one way, assuming you have an attribute containing the polygon ID and the CSV has the polygon vertices in the correct order:

  1. VertexCreator to convert X,Y values to point geometry
  2. LineBuilder, connection break attribute = your polygon ID
  3. LineCloser, only necessary if the polygons don't close completely
  4. GeometryCoercer set to "fme_polygon" (alternatively look at the AreaBuilder if you have donuts etc)

If you need more specific instructions, consider posting a small sample CSV dataset.


Depending on the actual schema of the CSV. If you could post a sample data, it would help us to think of a suitable way.


Here's one way, assuming you have an attribute containing the polygon ID and the CSV has the polygon vertices in the correct order:

  1. VertexCreator to convert X,Y values to point geometry
  2. LineBuilder, connection break attribute = your polygon ID
  3. LineCloser, only necessary if the polygons don't close completely
  4. GeometryCoercer set to "fme_polygon" (alternatively look at the AreaBuilder if you have donuts etc)

If you need more specific instructions, consider posting a small sample CSV dataset.

Thanks it is working

 

 


Reply