Select to view content in your preferred language

Dynamic Spatial Filter

104
7
16 hours ago
GaryBarden
Regular Contributor

Is it possible to apply a spatial filter to a layer that is based on a points location to a polygon layer that is frequently updated? The layer would be published and used in a map application where the user would see only the points within proximity to the most up-to-date version of the polygons.

 

0 Kudos
7 Replies
Robert_LeClair
Esri Esteemed Contributor

I wonder if this workflow, Spatially Filter Feature Layers with Definition Queries, would work for you?

0 Kudos
GaryBarden
Regular Contributor

It's a good idea, but that only selects features that intersect the geometry you select, I need "within a distance".

0 Kudos
Robert_LeClair
Esri Esteemed Contributor

Gotcha.  So question then - what type of map application will you be using?  Experience Builder?  Instant Apps?  Other?

Related - straight line distance or drive time/distance?

0 Kudos
GaryBarden
Regular Contributor

Experience Builder. Straight line distance.

0 Kudos
Robert_LeClair
Esri Esteemed Contributor

Okay.  So Experience Builder can do “points within a straight-line distance of polygons” using the Query widget (not the Filter widget).

Here are some steps you can try:

  1. Add a Query widget and set the data source to your points layer.
  2. In the Query widget, add a Spatial filter and choose Selected features from data source (the option that returns features that have a spatial relationship with features in another layer).
  3. Add filter layer = your polygons layer.
  4. Turn on Enable buffer and set the distance and units (this is the “within a distance” part).
  5. Use the Query result (output data source) to drive what the user sees (connect your Map/List/Table widgets to the query result).

You can learn more about the Query widget here - Query widget—ArcGIS Experience Builder | Documentation

0 Kudos
GaryBarden
Regular Contributor

The problem with this approach is that the Filter Layer only supports Selected features so I would have to add another step to the the workflow where users have to select the polygons first. 

The idea behind trying to filter the number of points before bringing them into the app is because there are just over 50k points that I'm trying to find within proximity to about 75 polygons. Trying to do this all within the app cause performance issues.

For additional clarification, the intended use of the app is to enable users to identify our assets that are within 10 miles of the wildfire perimeters in this layer (https://www.arcgis.com/home/item.html?id=d957997ccee7408287a963600a77f61f#overview)

0 Kudos
Robert_LeClair
Esri Esteemed Contributor

Understand.  So, sadly, in ArcGIS Pro, there isn’t a built-in dynamic spatial filter that continuously re-evaluates a layer as another layer’s geometry changes (including “within a distance”).  I know one can do this running a series of GP tools to ultimately get to the updated list point of points within 10 miles of a wildfire perimeter.  Presumably one could script the workflow and schedule the Python script to execute daily via Windows Task Scheduler.  Could do the same thing in ModelBuilder too.

0 Kudos