ArcGIS Pro

Dynamic Spatiotemporal Exploratory Analysis with Aggregated Results Using Time Series Data in ArcGIS

Starting ArcGIS Pro 2.8, authoring this kind of layers is made very easy using Make Aggregation Query Layer. Please read about this in the following blog and ArcGIS Pro help:


I have written two blog posts previously on this topic. There were basically two drawbacks in the approaches described in those posts:

 

To overcome these limitations, in ArcGIS Pro 1.4 we introduced parameters to query layers, allowing you to perform spatiotemporal and aggregate analysis dynamically from related tables. The advantages are significant with this new approach:

Consider

Query layer is the only kind of layer in ArcGIS Pro whose source can be a SQL statement, which could be as simple as “SELECT * FROM aTable” or very complex with joins, aggregated results, etc. The SQL query gets evaluated by the database, results get sent back, and a query layer draws the result in ArcGIS Pro. Query layers are only supported for enterprise databases such as SQL Server, PostgreSQL, and Oracle—they are not supported for file geodatabases. For that reason, the data needs to be copied to the enterprise database of your choice.

Prepare the Data

Let’s get started:

Catalog Pane - showing Rainfall.gdb
Catalog Pane - showing Rainfall.gdb

Compute Total Rainfall for Each Station

Next, we’ll create a table:

You will see that the table contains the total rainfall (dynamically computed) at each station for the entire four months. Since this table does not have spatial data, it cannot be drawn on a map.

This section is just to provide some background information. If you want, you can remove this table.

 

Visualize Total Rainfall on a Map

The USGS_Rainfall_Stations_IL feature class contains spatial data. We need to combine the computed total rainfall with spatial data. For this, we will use SQL joins and do the following:

Compute Total Rainfall for Any Time Duration

What we have so far is a layer where each station is populated with its total rainfall computed from all records off the time series table. What we want now is to draw rainfall stations with the total rainfall from a specific time duration—for instance, a week, a month, a three-day period, or any arbitrary time window.

Source tab on a Layer Properties page
Source tab on a Layer Properties page
Declare a range parameter in a SQL statement
Declare a range parameter in a SQL statement
Define a date range parameter
Define a date range parameter

If you click the Time tab on the Layer Properties page now, you will see that the time settings got automatically defined. When you define a range parameter of the Date data type, the layer is automatically made time aware and will start honoring the map’s time slider’s settings.

The time slider appears on the map.

You will see stations with their rainfall measurements for that week.

Use the time slider to go to another week, or change the time settings to view results for another window of time. If you want you can set the time span to bi-weekly or any arbitrary time duration, and you will see map is updated with dynamically computed total rainfall for that time duration.

Map showing total rainfall at stations for the week set on the time slider
Map showing total rainfall at stations for the week set on the time slider

Visualize Data with Moving/Rolling Averages

Now we’ll use time settings to view stations with moving/rolling averages while stepping through time:

Time tab settings to compute moving/rolling average rainfall
Time tab settings to compute moving/rolling average rainfall

Now step through time with the time slider. You will see that features are drawn with the three-day moving/rolling average as it moves forward one day for each time step. If you want to see weekly moving average, all you need to do is to set the Span value to 1 week.

Show Anomalies

In this section, we will see how to draw stations differently when their monthly rainfall exceeds the historical rainfall average for a given month.

 

In this case monthly rainfall averages are stored in a separate table named USGS_Rainfall_Avg table. We will now use data from that table to produce a map showing stations with anomalies in red:

Arcade expression to draw anomalies with different color
Arcade expression to draw anomalies with different color
Time tab's setting to show monthly anomalies
Time tab's setting to show monthly anomalies

This produces a map like the one below, where stations in red are the ones whose total rainfall for January 2013 exceeded the historic average rainfall for January.

Map showing monthly total rainfall and anomalies
Map showing monthly total rainfall and anomalies

Share and Consume Data in Web Maps

You can do the following:

About the author

Tanu is a product engineer on Esri Mapping Team focusing on map service, print service, and ArcGIS Pro. He also works on spatio-temporal analysis, spatial aggregation and real-time data. Tanu’s background includes a masters in Urban Planning from University of Akron, Ohio, USA and a bachelor degree from Khulna University, Bangladesh, and worked as GIS Coordinator in City of West Springfield, and GIS Specialist in a hydrology modeling center in Bangladesh before joining Esri.

Connect:
0 Comments
Inline Feedbacks
View all comments

Next Article

ArcGIS Monitor: Analysis Elements for Enterprise portal content

Read this article