Skip to main content
Question

data from raster in a polygon

  • May 20, 2020
  • 4 replies
  • 295 views

Hello,

I'm new in FME and I want to put, in a polygon, the minimum value (from a raster) in this polygon inside this polygon.

 

 

 

 

I use :

"RasterToPolygonCoercer" to extract data,

"AreaOnAreaOverlayer" to transfert data to polygon.

But I cannot think how to do this.

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

4 replies

ebygomm
Influencer
Forum|alt.badge.img+44
  • Influencer
  • 3427 replies
  • May 20, 2020

Have you tried clipping the raster with the polygon, then using a rasterstatistics calculator on the resulting clipped raster to get the minimum?


jdh
Contributor
Forum|alt.badge.img+37
  • Contributor
  • 2002 replies
  • May 20, 2020

@ebygomm has the right approach. You want to have a unique id on the polygons, if they don't already have one, you can use a Counter to create one. On the clipper, merge attributes. After the RasterStatisticsCalculator use a FeatureMerger/FeatureJoiner to join the band0.min value back to the original polygons based on the unique id.


ebygomm
Influencer
Forum|alt.badge.img+44
  • Influencer
  • 3427 replies
  • May 20, 2020

@ebygomm has the right approach. You want to have a unique id on the polygons, if they don't already have one, you can use a Counter to create one. On the clipper, merge attributes. After the RasterStatisticsCalculator use a FeatureMerger/FeatureJoiner to join the band0.min value back to the original polygons based on the unique id.

I normally store the geomety as an attribute with a geometryextractor then rebuild after with a geometryreplacer. Feels a bit neater than the featuremerger.


jdh
Contributor
Forum|alt.badge.img+37
  • Contributor
  • 2002 replies
  • May 20, 2020

I normally store the geomety as an attribute with a geometryextractor then rebuild after with a geometryreplacer. Feels a bit neater than the featuremerger.

That's an idea. I will need to do some performance tests to see which scenarios are better for which approach.