create an interactive comparison of values between two user-selected years in ArcGIS Dashboard or Experience Builder

222
2
Saturday
Nedamohamadzadeh
New Contributor

Hello everyone,

I’m new to using ArcGIS Online apps and I’m trying to build an interactive visualization for well water level data. I have a point shapefile showing well locations with water levels recorded over multiple years (about a decade).

What I’d like to do is create a Dashboard or Experience Builder app that allows users to:

  • Select two different years (e.g., 2010 and 2020) from dropdown menus or selectors, and

  • Automatically update the map symbology based on the difference in water levels between those two selected years.

I was able to create selectors in Dashboard, but I couldn’t figure out how to link the selections to an Arcade expression that calculates the difference dynamically.
In Experience Builder, I tried using Select and Filter widgets, but they only seem to work with a single field or with predefined comparisons—not interactively between two user-selected years.

Has anyone done something similar, or is there a tutorial or workflow you can recommend for creating this type of two-year comparison using Arcade or another method in Dashboard or Experience Builder?

Thank you in advance for your help!

0 Kudos
2 Replies
ShareUser
Esri Community Manager

@ShareUser are you set on having the difference displayed on a map? If you are open to displaying the difference number with an indicator, you could write a new data expression, bring in water level data twice,  subtract the two water level fields, returning the difference, which then you could display in an indicator, having it render only when the category selectors are activated.  With an indicator it would need to be on an individual site, but you could probably do a table similarly if you want to display multiple.  Not optimal but could get your functionality.

0 Kudos
ShareUser
Esri Community Manager

Thinking about this some more, easiest way might be to create a new feature layer with all the possible year -year combinations doing a 1 to many self join based on your site, and pre-calculate the differences in a in a new field in the resulting table.   Add that feature layer to your map and symbolize as you see fit. Then you would be able to use the two category selectors to filter in the dashboard.  This would appear dynamic, however it would need to be updated every time new data was added to the original dataset.  If that is frequent maybe a schedule python script to append new data. 

Depending what you want you could further pre-filter the data to get rid of and features where the first year selection is not more recent than the second year selection. 

0 Kudos