{"id":2481792,"date":"2024-09-16T08:40:35","date_gmt":"2024-09-16T15:40:35","guid":{"rendered":"https:\/\/www.esri.com\/arcgis-blog\/?post_type=blog&#038;p=2481792"},"modified":"2024-12-09T15:13:29","modified_gmt":"2024-12-09T23:13:29","slug":"real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity","status":"publish","type":"blog","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity","title":{"rendered":"Real-Time Change Detection with Arcade Track Functions in ArcGIS Velocity"},"author":361042,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"open","ping_status":"closed","template":"","format":"standard","meta":{"_acf_changed":false,"_searchwp_excluded":""},"categories":[777102,37121],"tags":[538822,221062,757411,776592,521922],"industry":[],"product":[756702],"class_list":["post-2481792","blog","type-blog","status-publish","format-standard","hentry","category-arcade","category-real-time","tag-iot","tag-location-intelligence","tag-real-time-analytics","tag-real-time-data-monitoring","tag-real-time-visualization","product-arcgis-velocity"],"acf":{"authors":[{"ID":361042,"user_firstname":"Joanna","user_lastname":"Nishimura","nickname":"Joanna Nishimura","user_nicename":"jnishimura","display_name":"Joanna Nishimura","user_email":"jnishimura@esri.com","user_url":"","user_registered":"2024-09-03 17:17:54","user_description":"Joanna Nishimura is a Product Engineer on the Real-Time Visualization and Analytics team at Esri.  In her free time, you can find Joanna enjoying the great outdoors.","user_avatar":"<img data-del=\"avatar\" src='https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/thumbnail2-213x200.jpg' class='avatar pp-user-avatar avatar-96 photo ' height='96' width='96'\/>"}],"short_description":"Use ArcGIS Velocity to monitor stream gauges and determine if water levels are increasing or decreasing based on previous observations.","flexible_content":[{"acf_fc_layout":"content","content":"<h3>Introduction<\/h3>\n<p>In this blog, we explore how to use Arcade Track Functions in ArcGIS Velocity to perform change detection. We will focus on monitoring stream gauges with the goal of assessing if water levels are increasing, decreasing, or have not changed since the last observation.<\/p>\n<p>In many situations, the <a href=\"https:\/\/doc.arcgis.com\/en\/iot\/analyze\/detect-incidents.htm\" target=\"_blank\" rel=\"noopener\">Detect Incidents<\/a> tool, available in real-time and big data analytics in Velocity, can open and close incidents when certain conditions exist in a continuous set of observations.\u00a0 The Detect Incidents tool could be used in a real-time analytic to open an incident whenever water levels at a gauge exceed 20 feet. However, our goal is to gain a deeper understanding of the relationship between current and previous stream gauge observations. To achieve this, we will use <a href=\"https:\/\/developers.arcgis.com\/arcade\/function-reference\/track_functions\/\" target=\"_blank\" rel=\"noopener\">Track Functions<\/a> to compare current and previous stream gauge heights and determine if water height is increasing, decreasing, or has not changed.<\/p>\n<h3>What is ArcGIS Velocity?<\/h3>\n<p>Velocity is the real-time and big data processing and analysis capability of ArcGIS Online. It allows you to ingest, visualize, analyze, and store data from Internet of Things (IoT) sensors. To learn more, visit Velocity\u2019s\u00a0<a href=\"https:\/\/www.esri.com\/en-us\/arcgis\/products\/arcgis-velocity\/overview#:~:text=ArcGIS%20Velocity%20is%20a%20cloud-native%20add-on%20capability%20for,big%20data%3B%20and%20perform%20fast%20queries%20and%20analysis.\" target=\"_blank\" rel=\"noopener\">product page<\/a> and <a href=\"https:\/\/www.esri.com\/en-us\/arcgis\/products\/arcgis-velocity\/resources\" target=\"_blank\" rel=\"noopener\">product documentation<\/a>.<\/p>\n<p>In Velocity analytics, tracks are sequentially ordered features (by Start Time key field) with a field specified as a track identifier (Track ID key field). For example, if you are monitoring moving fleet vehicles, the Track ID can be a field like the Vehicle ID, License Plate, or Driver ID. The features in the track are ordered by their date of arrival to the real-time analytic.<\/p>\n<h3>Getting Started<\/h3>\n<p>In this example, we will use data from the <a href=\"https:\/\/www.weather.gov\/media\/owp\/oh\/docs\/NWPS_API_Flyer_V6.pdf\" target=\"_blank\" rel=\"noopener\">National Water Prediction Service API<\/a>, which is provided by the National Water Service and the National Oceanic and Atmospheric Administration. \u00a0This API gives access to stream gauge observations, gauge metadata, and stream\/river flow forecasts in the United States.<\/p>\n<h4>Create a Feed<\/h4>\n<p>Let\u2019s create a feed that periodically pulls data from the National Water Prediction Service API and brings it into ArcGIS Velocity.<\/p>\n<p>With the ArcGIS Velocity interface open, click \u201cFeeds\u201d and then \u201c+ Create feed.\u201d\u00a0 Next, expand the option to \u201cSee all\u201d under \u201cWeb and Messaging,\u201d and then expand the \u201cHTTP\u201d menu and select \u201cHTTP Poller.\u201d\u00a0 After that, copy and paste the following URL into the URL input for the HTTP Poller:<\/p>\n"},{"acf_fc_layout":"content","content":"<pre><code style=\"color: #24292e;background: #ffffff;padding: 1em\">https:\/\/api.water.noaa.gov\/nwps\/v1\/gauges?bbox.xmin=-85.166016&amp;bbox.ymin=33.651208&amp;bbox.xmax=-75.421143&amp;bbox.ymax=36.941111&amp;srid=EPSG_4326<\/code><\/pre>\n"},{"acf_fc_layout":"content","content":"<p>The above URL will query stream gauges from the National Water Prediction Service API. Stream gauges within the bounding box (identified by the bbox parameters) are returned by the query. After that, click \u201cNext.\u201d<\/p>\n<p>The data is returned in nested JSON format. To access the data variables within the nested component, such as the stream gauge latitude and longitude, water heights, etc., specify a root node of \u201cgauges,\u201d and select the option to \u201cflatten\u201d the data. Then, proceed by selecting the \u201cDerive schema\u201d button. These changes will ensure that Velocity only parses data from the \u201cgauges\u201d object, and any other objects within the gauges object are shifted to a single level schema while maintaining the original object(s) names.<\/p>\n<p>After deriving the new schema, we get access to the data variables contained within the nested JSON, which includes a unique ID for each stream gauge in a field called \u201clid\u201d and each gauge\u2019s current reading in a variable called \u201cstatus_observed_primary.\u201d\u00a0 Keep the default field names and click \u201cNext.\u201d<\/p>\n<p>In the Identify Key Fields pane, select \u201cLocation type\u201d as \u201cX\/Y fields\u201d and choose \u201clongitude\u201d for \u201cX\u201d, \u201clatitude\u201d for \u201cY,\u201d and GCS WGS 1984 for \u201cSpatial reference.\u201d Then, choose \u201cYes\u201d for the question \u201cDoes your data have date fields\u201d and select \u201cstatus_observed_validTime\u201d for the \u201cStart time\u201d field.\u00a0 Next, copy and paste the following date and time format for the \u201cDate Formatting String.\u201d<\/p>\n<pre><code style=\"color: #24292e;background: #ffffff;padding: 1em\">yyyy-MM-dd'T'HH:mm:ss'Z'<\/code><\/pre>\n<p>Set the \u201cTrack ID\u201d to \u201clid\u201d and then select \u201cNext.\u201d<\/p>\n<p>For the Feed Polling Interval, set the feed to \u201cRuns periodically\u201d every 15 minutes on \u201cEvery day\u201d, then click \u201cNext\u201d. Give the feed a name, such as \u201cstreamGaugesNC\u201d and click \u201cComplete.\u201d<\/p>\n<p><em>Note- This HTTP Poller will return stream gauges that fall within a bounding box which covers North Carolina. Modifying the bounding box parameters will allow you to receive stream gauges for different areas of the United States. You can find more information about querying the API <a href=\"https:\/\/www.weather.gov\/media\/owp\/oh\/docs\/NWPS_API_Flyer_V6.pdf\" target=\"_blank\" rel=\"noopener\">here<\/a>.<\/em><\/p>\n<p><em>Note- The HTTP Poller feed polls the API every 15 minutes, but this time interval can be adjusted. The minimum poll interval for the HTTP Poller feed is every 10 seconds. While I was investigating the stream gauge data, it appeared that most of the gauges were updating once every 15 minutes, so I opted for the 15-minute poll interval.<\/em><\/p>\n"},{"acf_fc_layout":"image","image":{"ID":2485892,"id":2485892,"title":"Create Stream Gauge Feed in ArcGIS Velocity","filename":"01_createStreamGaugeFeed.gif","filesize":6786603,"url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/01_createStreamGaugeFeed.gif","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\/01_createstreamgaugefeed","alt":"Create a feed which ingests real-time stream gauge data.","author":"361042","description":"","caption":"Create a feed in ArcGIS Velocity to ingest real-time stream gauge data from the National Water Prediction Service API.","name":"01_createstreamgaugefeed","status":"inherit","uploaded_to":2481792,"date":"2024-09-11 17:07:25","modified":"2024-09-11 23:10:43","menu_order":0,"mime_type":"image\/gif","type":"image","subtype":"gif","icon":"https:\/\/www.esri.com\/arcgis-blog\/wp-includes\/images\/media\/default.png","width":1920,"height":1080,"sizes":{"thumbnail":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/01_createStreamGaugeFeed-213x200.gif","thumbnail-width":213,"thumbnail-height":200,"medium":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/01_createStreamGaugeFeed.gif","medium-width":464,"medium-height":261,"medium_large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/01_createStreamGaugeFeed.gif","medium_large-width":768,"medium_large-height":432,"large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/01_createStreamGaugeFeed.gif","large-width":1920,"large-height":1080,"1536x1536":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/01_createStreamGaugeFeed-1536x864.gif","1536x1536-width":1536,"1536x1536-height":864,"2048x2048":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/01_createStreamGaugeFeed.gif","2048x2048-width":1920,"2048x2048-height":1080,"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/01_createStreamGaugeFeed-826x465.gif","card_image-width":826,"card_image-height":465,"wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/01_createStreamGaugeFeed.gif","wide_image-width":1920,"wide_image-height":1080}},"image_position":"center","orientation":"horizontal","hyperlink":""},{"acf_fc_layout":"content","content":"<h3>Create a Real-Time Analytic<\/h3>\n<p>Once you have created your feed, add it to a new real-time analytic. The tools in the real-time analytic will process every feature received from the stream gauge feed.<\/p>\n<h4>Step 1: Add and Configure the Filter by Expression Tool<\/h4>\n<p>To add and configure the Filter by Expression tool, click the \u201c+\u201d button on the left pane of the real-time analytic, expand the \u201cManage Data\u201d folder, and then select the \u201cFilter by Expression\u201d tool. Next, drag the output port from the stream gauge feed and connect it to the target port of the Filter by Expression tool.<\/p>\n<p>Double-click the Filter by Expression tool (or right-click \u00a0and select \u201cview properties\u201d) to open the tool properties pane. Then, click \u201cConfigure an Arcade expression\u201d to open the Arcade code editor. Copy and paste the following Arcade expression into the editor, click \u201cRun\u201d to evaluate the expression, and then select \u201cOK\u201d to complete the process.<\/p>\n<pre><code style=\"color: #24292e;background: #ffffff;padding: 1em\"><span style=\"color: #e36209\">$feature<\/span>.status_observed_primary &gt;= <span style=\"color: #005cc5\">0<\/span> &amp;&amp; \r\n<span style=\"color: #e36209\">$feature<\/span>.status_observed_floodCategory != <span style=\"color: #032f62\">'out_of_service'<\/span> &amp;&amp; \r\n<span style=\"color: #e36209\">$feature<\/span>.status_observed_floodCategory != <span style=\"color: #032f62\">'not_defined'<\/span>\r\n<\/code><\/pre>\n<p>This Arcade expression in the Filter by Expression tool evaluates the stream gauge data received. We use this tool to remove stream gauges that are returning potentially erroneous data (water height values &lt; 0) or have status values of \u201cout_of_service\u201d or \u201cnot_defined.\u201d Select \u201cApply\u201d to add the Arcade Expression.<\/p>\n"},{"acf_fc_layout":"image","image":{"ID":2486062,"id":2486062,"title":"Filter by Expression tool in ArcGIS Velocity","filename":"02_addFilterByExpression.gif","filesize":9619948,"url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/02_addFilterByExpression.gif","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\/02_addfilterbyexpression","alt":"Use the Filter by Expression tool to remove stream gauges from the analytic that are offline or may be reporting inaccurate data.","author":"361042","description":"","caption":"Use the Filter by Expression tool to remove stream gauges from the analytic which are offline or may be reporting inaccurate data.","name":"02_addfilterbyexpression","status":"inherit","uploaded_to":2481792,"date":"2024-09-11 17:58:12","modified":"2024-09-11 23:11:22","menu_order":0,"mime_type":"image\/gif","type":"image","subtype":"gif","icon":"https:\/\/www.esri.com\/arcgis-blog\/wp-includes\/images\/media\/default.png","width":1620,"height":764,"sizes":{"thumbnail":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/02_addFilterByExpression-213x200.gif","thumbnail-width":213,"thumbnail-height":200,"medium":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/02_addFilterByExpression.gif","medium-width":464,"medium-height":219,"medium_large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/02_addFilterByExpression.gif","medium_large-width":768,"medium_large-height":362,"large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/02_addFilterByExpression.gif","large-width":1620,"large-height":764,"1536x1536":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/02_addFilterByExpression-1536x724.gif","1536x1536-width":1536,"1536x1536-height":724,"2048x2048":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/02_addFilterByExpression.gif","2048x2048-width":1620,"2048x2048-height":764,"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/02_addFilterByExpression-826x390.gif","card_image-width":826,"card_image-height":390,"wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/02_addFilterByExpression.gif","wide_image-width":1620,"wide_image-height":764}},"image_position":"center","orientation":"horizontal","hyperlink":""},{"acf_fc_layout":"content","content":"<h4>Step 2: Add and Configure the Calculate Field Tool<\/h4>\n<p>To add and configure the calculate field tool, click the \u201c+\u201d button on the left pane of the real-time analytic, expand the \u201cManage Data\u201d folder, and select \u201cCalculate Field\u201d tool. Drag the output port from the Filter by Expression tool and connect it to the target port of the Calculate Field tool.<\/p>\n<p>Double-click the Calculate Field tool ( or right-click\u00a0 and select \u201cview properties\u201d) to open the tool properties pane. Click \u201cAdd field calculation\u201d and then click \u201cNew field.\u201d\u00a0 Give the field the name \u201cprevChange\u201d and select \u201cFloat 64\u201d as \u201cType.\u201d Click \u201cConfigure an Arcade expression\u201d and copy and paste the following Arcade expression into the code editor.<\/p>\n<pre><code style=\"color: #24292e;background: #ffffff;padding: 1em\"><span style=\"color: #6a737d\">\/\/ Part 1: Return previous observation heights and current observation height<\/span>\r\n<span style=\"color: #d73a49\">var<\/span> previousAndCurrent = <span style=\"color: #e36209\">TrackFieldWindow<\/span>(<span style=\"color: #032f62\">'status_observed_primary'<\/span>, <span style=\"color: #005cc5\">-1<\/span>, <span style=\"color: #005cc5\">1<\/span>); \r\n<span style=\"color: #d73a49\">var<\/span> numFeatures = <span style=\"color: #e36209\">Count<\/span>(previousAndCurrent); \r\n\r\n<span style=\"color: #6a737d\">\/\/ Part 2: If there are less than 2 features in the returned array, return -999<\/span>\r\n<span style=\"color: #d73a49\">if<\/span> (numFeatures &lt; <span style=\"color: #005cc5\">2<\/span>) { \r\n  <span style=\"color: #d73a49\">return<\/span> <span style=\"color: #005cc5\">-999<\/span>; \r\n  } \r\n<span style=\"color: #6a737d\">\/\/ else, return the difference in observation height values<\/span>\r\n  <span style=\"color: #d73a49\">else<\/span> { \r\n    <span style=\"color: #d73a49\">var<\/span> current = previousAndCurrent[<span style=\"color: #005cc5\">1<\/span>]\r\n    <span style=\"color: #d73a49\">var<\/span> previous = previousAndCurrent[<span style=\"color: #005cc5\">0<\/span>]\r\n    <span style=\"color: #d73a49\">var<\/span> heightDifference = current - previous;\r\n    <span style=\"color: #d73a49\">return<\/span> <span style=\"color: #e36209\">Round<\/span>(heightDifference, <span style=\"color: #005cc5\">2<\/span>);\r\n  }\r\n<\/code><\/pre>\n"},{"acf_fc_layout":"content","content":"<p>The above Arcade expression uses a Track Function to access the current water height and previous water height recorded by stream gauges. In real-time analytics, Track Functions enable access to prior observations for the same Track ID.\u00a0 Track Functions are only supported in the Arcade expression editor of the Calculate Fields and Map Fields tools of Velocity currently. In our case, we will only use the Track Function called TrackFieldWindow, although there are 15 other Track Functions available in ArcGIS Velocity. More information about Track Functions in\u00a0 Velocity can be found <a href=\"https:\/\/doc.arcgis.com\/en\/iot\/analyze\/use-track-functions.htm#:~:text=Track%20functions%20allow%20you%20to,and%20a%20Start%20Time%20field.\" target=\"_blank\" rel=\"noopener\">here<\/a>.<\/p>\n<p>In Part 1 of the above code snippet, we create a new variable called <code>previousAndCurrent<\/code>, which will store the outputs of the <a href=\"https:\/\/developers.arcgis.com\/arcade\/function-reference\/track_functions\/#:~:text=TrackFieldWindow(fieldName%2C%20startIndex%2C%20endIndex,)%20%2D%3E%20Array&amp;text=Returns%20an%20array%20of%20attribute,forward%20and%20backward%20in%20time.&amp;text=fieldName%3A%20Text%20%2D%20The%20field%20name%20from%20which%20to%20return%20values.\" target=\"_blank\" rel=\"noopener\">TrackFieldWindow<\/a> function. The TrackFieldWindow function requires three parameters:<\/p>\n<ol>\n<li>A field name (as a string value) that represents the field of interest<\/li>\n<li>A start index number, where an index of \u20131 represents the prior feature (inclusive of this feature)<\/li>\n<li>An end index number, where an index of 0 represents the current feature (exclusive of this feature)<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<p>In our use of the TrackFieldWindow function, we return the previous observation, which is at a start index of \u20131, and the current observation, which is at an index value of 0.\u00a0 Observation values will come from a field\u00a0called &#8220;status_observed_primary&#8221; and the outputs from the TrackFieldWindow function are returned in an array called <code>previousAndCurrent<\/code>.<\/p>\n<p>We then return the count of items in the <code>previousAndCurrent<\/code> array. Despite stating that we would only return two values from the TrackFieldWindow function (the previous and current observation) why could there be less than two values in our returned array? This can occur if the analytic has not run long enough or if new observations have not been received from the stream gauge.<\/p>\n<p>In Part 2 of the code snippet, we return different outputs based on the count of features in the <code>previousAndCurrent<\/code> array. We account for situations where the <code>previousAndCurrent<\/code> array may have fewer than two values by using an if-else statement. If the <code>numFeatures<\/code> variable is less than two, then we will return a value of \u2013999. However, if the number of items in the <code>numFeatures<\/code> variable is equal to two, then we create three more variables:<\/p>\n<ol>\n<li><code>var current<\/code> holds the second item from the <code>previousAndCurrent<\/code> array (the item at index value 1)<\/li>\n<li><code>var previous<\/code> holds the first item from the <code>previousAndCurrent<\/code> array (the item at index value 0)<\/li>\n<li><code>var heightDifference<\/code>\u00a0holds the difference between the current and previous stream gauge readings.<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<p>Finally, we round the output to return the <code>heightDifference<\/code> variable with only two digits. This variable is the difference between the current and previous stream gauge height observations.<\/p>\n<p>In the Arcade editor, click \u201cRun\u201d to evaluate the expression, and then select \u201cOK\u201d to complete the process. Select \u201cAdd Field Calculation\u201d and then \u201cApply\u201d to add the Arcade Expression.<\/p>\n"},{"acf_fc_layout":"image","image":{"ID":2486082,"id":2486082,"title":"Calculate Field Tool in ArcGIS Velocity","filename":"03_calculateFieldTool1.gif","filesize":6525625,"url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/03_calculateFieldTool1.gif","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\/03_calculatefieldtool1","alt":"Use the Calculate Field tool to access previous and current stream gauge height observations.","author":"361042","description":"","caption":"Use the Calculate Field tool to access stream gauge water height values from current and previous observations.","name":"03_calculatefieldtool1","status":"inherit","uploaded_to":2481792,"date":"2024-09-11 18:01:26","modified":"2024-09-11 23:13:02","menu_order":0,"mime_type":"image\/gif","type":"image","subtype":"gif","icon":"https:\/\/www.esri.com\/arcgis-blog\/wp-includes\/images\/media\/default.png","width":1620,"height":764,"sizes":{"thumbnail":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/03_calculateFieldTool1-213x200.gif","thumbnail-width":213,"thumbnail-height":200,"medium":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/03_calculateFieldTool1.gif","medium-width":464,"medium-height":219,"medium_large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/03_calculateFieldTool1.gif","medium_large-width":768,"medium_large-height":362,"large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/03_calculateFieldTool1.gif","large-width":1620,"large-height":764,"1536x1536":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/03_calculateFieldTool1-1536x724.gif","1536x1536-width":1536,"1536x1536-height":724,"2048x2048":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/03_calculateFieldTool1.gif","2048x2048-width":1620,"2048x2048-height":764,"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/03_calculateFieldTool1-826x390.gif","card_image-width":826,"card_image-height":390,"wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/03_calculateFieldTool1.gif","wide_image-width":1620,"wide_image-height":764}},"image_position":"center","orientation":"horizontal","hyperlink":""},{"acf_fc_layout":"content","content":"<h4>Step 3: Add and Configure the Calculate Field tool (again!)<\/h4>\n<p>To add and configure the Calculate Field tool, click the \u201c+\u201d button on the left pane of the real-time analytic, expand the \u201cManage Data\u201d folder, then select \u201cCalculate Field\u201d tool. Next, drag the output port from the first Calculate Field tool to the target port of the new Calculate Field tool. This will add a second Calculate Field tool, which will allow us to access the new field created from the first Calculate Field tool.<\/p>\n<p>Double-click the Calculate Field tool (or right-click \u00a0and select \u201cview properties\u201d) to open the tool properties pane. Select \u201cAdd field calculation\u201d and then choose \u201cNew field.\u201d\u00a0 Name the field \u201cobsTrend\u201d and select the type as \u201cString.\u201d\u00a0 Then, select \u201cConfigure an Arcade expression,\u201d and copy and paste the following Arcade expression into the code editor:<\/p>\n<pre><code style=\"color: #24292e;background: #ffffff;padding: 1em\">\r\n<span style=\"color: #d73a49\">var<\/span> change = <span style=\"color: #e36209\">$feature<\/span>.prevChange;\r\n<span style=\"color: #d73a49\">var<\/span> trend = <span style=\"color: #032f62\">\"\"<\/span>;\r\n\r\n<span style=\"color: #d73a49\">if<\/span>(change == <span style=\"color: #005cc5\">-999<\/span>){\r\n  trend = <span style=\"color: #032f62\">\"No trend data can be generated\"<\/span>;\r\n} <span style=\"color: #d73a49\">else<\/span> <span style=\"color: #d73a49\">if<\/span>(change &lt; <span style=\"color: #005cc5\">0<\/span>){\r\n  trend = <span style=\"color: #032f62\">\"Falling\"<\/span>\r\n} <span style=\"color: #d73a49\">else<\/span> <span style=\"color: #d73a49\">if<\/span>(change == <span style=\"color: #005cc5\">0<\/span>){\r\n  trend = <span style=\"color: #032f62\">\"No change\"<\/span>\r\n} <span style=\"color: #d73a49\">else<\/span> {\r\n  trend = <span style=\"color: #032f62\">\"Rising\"<\/span>\r\n}\r\n<span style=\"color: #d73a49\">return<\/span> trend;\r\n<\/code><\/pre>\n"},{"acf_fc_layout":"content","content":"<p>The Arcade expression above accesses the output from the previous Calculate Field tool, which is a new field called prevChange. There are four potential scenarios:<\/p>\n<ol>\n<li>If the <code>prevChange<\/code> field has a value of \u2013999, it means there is no previous stream gauge data currently available.<\/li>\n<li>If the <code>prevChange<\/code> field has a negative value, it means that the current stream gauge reading is less than the previous value (the water level is decreasing).<\/li>\n<li>If the <code>prevChange<\/code> field has a value of 0, it means that the current stream gauge reading is the same as the previous value (the water level has not changed between readings).<\/li>\n<li>If the above statements are false, then <code>prevChange<\/code> field must have a value greater than 0, which means that the current stream gauge reading is higher than the previous value (the water level is increasing).<\/li>\n<\/ol>\n<p>&nbsp;<\/p>\n<p>We account for those scenarios in the if-else expression and output results in the <code>trend<\/code> variable.<\/p>\n<p>In the Arcade editor, click \u201cRun\u201d to evaluate the expression and then select \u201cOK\u201d to complete the process. Select \u201cAdd field calculation\u201d and \u201cApply\u201d to add the Arcade Expression.<\/p>\n<p><em>Note- Both the calculation for the field <code>prevChange<\/code> and the calculation for the field <code>trend<\/code> could be combined into one Calculate Field tool. We decided to split the calculations out into two tools for improved clarity.<\/em><\/p>\n"},{"acf_fc_layout":"image","image":{"ID":2486092,"id":2486092,"title":"Calculate Field tool in AcGIS Velocity","filename":"04_calculateFieldTool2.gif","filesize":6701407,"url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/04_calculateFieldTool2.gif","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\/04_calculatefieldtool2","alt":"Use the Calculate Field tool to determine if changes in stream gauge heights are able to be determined, are falling, are rising, or have experienced no change.","author":"361042","description":"","caption":"Use a second instance of the Calculate Field tool to determine if water heights are stream gauges are falling, rising, have experienced no change, or cannot be calculated due to insufficient observations.","name":"04_calculatefieldtool2","status":"inherit","uploaded_to":2481792,"date":"2024-09-11 18:01:59","modified":"2024-09-11 23:14:39","menu_order":0,"mime_type":"image\/gif","type":"image","subtype":"gif","icon":"https:\/\/www.esri.com\/arcgis-blog\/wp-includes\/images\/media\/default.png","width":1620,"height":764,"sizes":{"thumbnail":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/04_calculateFieldTool2-213x200.gif","thumbnail-width":213,"thumbnail-height":200,"medium":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/04_calculateFieldTool2.gif","medium-width":464,"medium-height":219,"medium_large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/04_calculateFieldTool2.gif","medium_large-width":768,"medium_large-height":362,"large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/04_calculateFieldTool2.gif","large-width":1620,"large-height":764,"1536x1536":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/04_calculateFieldTool2-1536x724.gif","1536x1536-width":1536,"1536x1536-height":724,"2048x2048":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/04_calculateFieldTool2.gif","2048x2048-width":1620,"2048x2048-height":764,"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/04_calculateFieldTool2-826x390.gif","card_image-width":826,"card_image-height":390,"wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/04_calculateFieldTool2.gif","wide_image-width":1620,"wide_image-height":764}},"image_position":"center","orientation":"horizontal","hyperlink":""},{"acf_fc_layout":"content","content":"<h4>Step 4: Add a New Output and Save the Analytic<\/h4>\n<p>To add a new output and save the analytic, click the \u201c+\u201d button on the left pane of the real-time analytic, expand the \u201cOutput Data\u201d folder, then select \u201cFeature Layer (new)\u201d option. Keep the default option to \u201cstore data in the spatiotemporal feature layer\u201d and select \u201cKeep only latest feature for each Track ID value\u201d as the Data Storage Method. Choose \u201cReplace existing features and schema\u201d each time the analytic starts. Give the output feature layer a new name, such as \u201cstreamGaugeData.\u201d<\/p>\n<p>In the upper right, click \u00a0\u201cCreate analytic\u201d and enter a new name for the real-time analytic. Next, click \u201cStart\u201d to begin the initialization process, which may take several minutes.<\/p>\n"},{"acf_fc_layout":"image","image":{"ID":2486342,"id":2486342,"title":"Output to Feature Layer and Create a Real Time Analytic","filename":"05_addAnOutputAndSave.gif","filesize":9021980,"url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/05_addAnOutputAndSave.gif","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\/05_addanoutputandsave","alt":"Output data to a new feature layer and save the real-time analytic.","author":"361042","description":"","caption":"Add an output feature layer and save and start the real-time analytic to being processing data.","name":"05_addanoutputandsave","status":"inherit","uploaded_to":2481792,"date":"2024-09-11 18:38:12","modified":"2024-09-11 23:15:35","menu_order":0,"mime_type":"image\/gif","type":"image","subtype":"gif","icon":"https:\/\/www.esri.com\/arcgis-blog\/wp-includes\/images\/media\/default.png","width":1920,"height":1080,"sizes":{"thumbnail":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/05_addAnOutputAndSave-213x200.gif","thumbnail-width":213,"thumbnail-height":200,"medium":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/05_addAnOutputAndSave.gif","medium-width":464,"medium-height":261,"medium_large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/05_addAnOutputAndSave.gif","medium_large-width":768,"medium_large-height":432,"large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/05_addAnOutputAndSave.gif","large-width":1920,"large-height":1080,"1536x1536":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/05_addAnOutputAndSave-1536x864.gif","1536x1536-width":1536,"1536x1536-height":864,"2048x2048":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/05_addAnOutputAndSave.gif","2048x2048-width":1920,"2048x2048-height":1080,"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/05_addAnOutputAndSave-826x465.gif","card_image-width":826,"card_image-height":465,"wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/05_addAnOutputAndSave.gif","wide_image-width":1920,"wide_image-height":1080}},"image_position":"center","orientation":"horizontal","hyperlink":""},{"acf_fc_layout":"content","content":"<h4>Step 5: Wait for Data\u2026<\/h4>\n<p>The HTTP Poller feed is set to return stream gauge data every 15 minutes. Polling occurs at regular time intervals, so if our HTTP Poller is started at 12:08 p.m., the first request for data will occur at 12:15 p.m., the next at 12:30 p.m., and so on. This means that even if the real-time analytic has initialized and is running, there might not be any data returned at that moment from the HTTP Poller feed. So, take a break and check on the analytic later.<\/p>\n<p>After about 45 minutes, I checked the real-time analytic and added the output feature layer to a new web map. Once added to my web map, I disabled the time animations on the layer and enabled the layer to automatically refresh every 0.5 minutes. I set the layer symbology to the field called \u201cobsTrend\u201d and used a blue upward facing arrow for field values of \u201cRising\u201d, a downward green arrow for values of \u201cFalling\u201d, a horizontal line for gauges with no change, and a square for gauges where \u201cno trend data can be generated.\u201d<\/p>\n"},{"acf_fc_layout":"image","image":{"ID":2486072,"id":2486072,"title":"Final output","filename":"06_finalStreamGaugeChange.gif","filesize":831443,"url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/06_finalStreamGaugeChange.gif","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\/06_finalstreamgaugechange","alt":"The output feature layer containing stream gauge data is symbolized. If not trend data can be generated, gauges are symbolized with a black square. Stream gauges increasing in height are symbolizing with upward arrows. Stream gauges decreasing in height are symbolized with downward arrows. Stream gauges exhibiting no change in height are symbolize with a horizontal line.","author":"361042","description":"","caption":"This is the final output feature layer.  Stream gauges which are experiencing rising water levels are symbolized with blue upwards arrows, gauges experiencing decreasing water levels are symbolized with green downwards arrows, and stream gauges exhibiting no change in water level are symbolized with horizontal lines.  ","name":"06_finalstreamgaugechange","status":"inherit","uploaded_to":2481792,"date":"2024-09-11 17:59:34","modified":"2024-09-11 23:16:54","menu_order":0,"mime_type":"image\/gif","type":"image","subtype":"gif","icon":"https:\/\/www.esri.com\/arcgis-blog\/wp-includes\/images\/media\/default.png","width":1644,"height":720,"sizes":{"thumbnail":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/06_finalStreamGaugeChange-213x200.gif","thumbnail-width":213,"thumbnail-height":200,"medium":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/06_finalStreamGaugeChange.gif","medium-width":464,"medium-height":203,"medium_large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/06_finalStreamGaugeChange.gif","medium_large-width":768,"medium_large-height":336,"large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/06_finalStreamGaugeChange.gif","large-width":1644,"large-height":720,"1536x1536":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/06_finalStreamGaugeChange-1536x673.gif","1536x1536-width":1536,"1536x1536-height":673,"2048x2048":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/06_finalStreamGaugeChange.gif","2048x2048-width":1644,"2048x2048-height":720,"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/06_finalStreamGaugeChange-826x362.gif","card_image-width":826,"card_image-height":362,"wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/06_finalStreamGaugeChange.gif","wide_image-width":1644,"wide_image-height":720}},"image_position":"center","orientation":"horizontal","hyperlink":""},{"acf_fc_layout":"content","content":"<p>In the event of an emergency, this visualization can help us better understand flood situations by visually tracking the rise and fall of flood waters.<\/p>\n<h3>Conclusion<\/h3>\n<p>This is just one example of using Track Functions in Velocity. Track Functions provide unique access to historical observations of data, grouped by Track ID and ordered by timestamp. This example used the TrackFieldWindow function; however, there are <a href=\"https:\/\/doc.arcgis.com\/en\/iot\/analyze\/use-track-functions.htm#:~:text=Track%20functions%20allow%20you%20to,and%20a%20Start%20Time%20field.\" target=\"_blank\" rel=\"noopener\">15 other Track Functions<\/a> available in Velocity. Check out this <a href=\"https:\/\/community.esri.com\/t5\/arcgis-velocity-blog\/using-arcade-trackgeometrywindow-function-in\/ba-p\/1407251\" target=\"_blank\" rel=\"noopener\">blog<\/a> to learn about using the TrackGeometryWindow function to access prior geometry values.<\/p>\n<p>To further expand on this current example, I might:<\/p>\n<ul>\n<li>Add a new TrackFieldWindow field calculation and adjust the time window to return the last four observations. Then, average those observations to get a better understanding of stream gauge height over the last hour.<\/li>\n<li>Add a new field calculation to calculate the percent change in stream gauge height from the last observation to the current one. Use this calculated value as a second field to symbolize on, allowing us to visualize which stream gauges are increasing or decreasing in height and the magnitude of change.<\/li>\n<li>Use the Control Event Volume tool with Email output to receive an email notification whenever a stream gauge experiences a notable change in water level between the last observation and the current one.<\/li>\n<\/ul>\n<p>We are always looking to hear back from the community, if you have any additional questions, please reach out to our team on the <a href=\"https:\/\/community.esri.com\/t5\/arcgis-velocity\/ct-p\/arcgis-velocity\" target=\"_blank\" rel=\"noopener\">ArcGIS Velocity Community<\/a>.<\/p>\n"}],"related_articles":[{"ID":2279462,"post_author":"4971","post_date":"2024-03-08 11:35:03","post_date_gmt":"2024-03-08 19:35:03","post_content":"","post_title":"What's new in ArcGIS Velocity (March 2024)","post_excerpt":"","post_status":"publish","comment_status":"open","ping_status":"closed","post_password":"","post_name":"whats-new-in-arcgis-velocity-march-2024","to_ping":"","pinged":"","post_modified":"2024-03-08 11:35:03","post_modified_gmt":"2024-03-08 19:35:03","post_content_filtered":"","post_parent":0,"guid":"https:\/\/www.esri.com\/arcgis-blog\/?post_type=blog&#038;p=2279462","menu_order":0,"post_type":"blog","post_mime_type":"","comment_count":"0","filter":"raw"}],"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/CARD_VelocityStream_826x465-1.png","wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/WIDE_VelocityStream_1920x1080-1.png","show_article_image":false},"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v25.9 (Yoast SEO v25.9) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Real-Time Monitoring of Stream Gauges with ArcGIS Velocity<\/title>\n<meta name=\"description\" content=\"Learn how to use ArcGIS Velocity to perform real-time monitoring of stream gauges and detect changes in water levels.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Real-Time Change Detection with Arcade Track Functions in ArcGIS Velocity\" \/>\n<meta property=\"og:description\" content=\"Learn how to use ArcGIS Velocity to perform real-time monitoring of stream gauges and detect changes in water levels.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\" \/>\n<meta property=\"og:site_name\" content=\"ArcGIS Blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/esrigis\/\" \/>\n<meta property=\"article:modified_time\" content=\"2024-12-09T23:13:29+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:site\" content=\"@ESRI\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"13 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":[\"Article\",\"BlogPosting\"],\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\"},\"author\":{\"name\":\"Joanna Nishimura\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/65ee270a38fca7d22f4cecc04dded9f2\"},\"headline\":\"Real-Time Change Detection with Arcade Track Functions in ArcGIS Velocity\",\"datePublished\":\"2024-09-16T15:40:35+00:00\",\"dateModified\":\"2024-12-09T23:13:29+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\"},\"wordCount\":10,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#organization\"},\"keywords\":[\"IoT\",\"Location intelligence\",\"real-time analytics\",\"real-time data monitoring\",\"real-time visualization\"],\"articleSection\":[\"Arcade\",\"Real-Time Visualization &amp; Analytics\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\",\"url\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\",\"name\":\"Real-Time Monitoring of Stream Gauges with ArcGIS Velocity\",\"isPartOf\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#website\"},\"datePublished\":\"2024-09-16T15:40:35+00:00\",\"dateModified\":\"2024-12-09T23:13:29+00:00\",\"description\":\"Learn how to use ArcGIS Velocity to perform real-time monitoring of stream gauges and detect changes in water levels.\",\"breadcrumb\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.esri.com\/arcgis-blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Real-Time Change Detection with Arcade Track Functions in ArcGIS Velocity\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#website\",\"url\":\"https:\/\/www.esri.com\/arcgis-blog\/\",\"name\":\"ArcGIS Blog\",\"description\":\"Get insider info from Esri product teams\",\"publisher\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.esri.com\/arcgis-blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#organization\",\"name\":\"Esri\",\"url\":\"https:\/\/www.esri.com\/arcgis-blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/04\/Esri.png\",\"contentUrl\":\"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/04\/Esri.png\",\"width\":400,\"height\":400,\"caption\":\"Esri\"},\"image\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/esrigis\/\",\"https:\/\/x.com\/ESRI\",\"https:\/\/www.linkedin.com\/company\/5311\/\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/65ee270a38fca7d22f4cecc04dded9f2\",\"name\":\"Joanna Nishimura\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/thumbnail2-213x200.jpg\",\"contentUrl\":\"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/thumbnail2-213x200.jpg\",\"caption\":\"Joanna Nishimura\"},\"description\":\"Joanna Nishimura is a Product Engineer on the Real-Time Visualization and Analytics team at Esri. In her free time, you can find Joanna enjoying the great outdoors.\",\"url\":\"\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Real-Time Monitoring of Stream Gauges with ArcGIS Velocity","description":"Learn how to use ArcGIS Velocity to perform real-time monitoring of stream gauges and detect changes in water levels.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity","og_locale":"en_US","og_type":"article","og_title":"Real-Time Change Detection with Arcade Track Functions in ArcGIS Velocity","og_description":"Learn how to use ArcGIS Velocity to perform real-time monitoring of stream gauges and detect changes in water levels.","og_url":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity","og_site_name":"ArcGIS Blog","article_publisher":"https:\/\/www.facebook.com\/esrigis\/","article_modified_time":"2024-12-09T23:13:29+00:00","twitter_card":"summary_large_image","twitter_site":"@ESRI","twitter_misc":{"Est. reading time":"13 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":["Article","BlogPosting"],"@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity#article","isPartOf":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity"},"author":{"name":"Joanna Nishimura","@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/65ee270a38fca7d22f4cecc04dded9f2"},"headline":"Real-Time Change Detection with Arcade Track Functions in ArcGIS Velocity","datePublished":"2024-09-16T15:40:35+00:00","dateModified":"2024-12-09T23:13:29+00:00","mainEntityOfPage":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity"},"wordCount":10,"commentCount":0,"publisher":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/#organization"},"keywords":["IoT","Location intelligence","real-time analytics","real-time data monitoring","real-time visualization"],"articleSection":["Arcade","Real-Time Visualization &amp; Analytics"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity","url":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity","name":"Real-Time Monitoring of Stream Gauges with ArcGIS Velocity","isPartOf":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/#website"},"datePublished":"2024-09-16T15:40:35+00:00","dateModified":"2024-12-09T23:13:29+00:00","description":"Learn how to use ArcGIS Velocity to perform real-time monitoring of stream gauges and detect changes in water levels.","breadcrumb":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/arcgis-velocity\/real-time\/real-time-change-detection-with-arcade-track-functions-in-arcgis-velocity#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.esri.com\/arcgis-blog\/"},{"@type":"ListItem","position":2,"name":"Real-Time Change Detection with Arcade Track Functions in ArcGIS Velocity"}]},{"@type":"WebSite","@id":"https:\/\/www.esri.com\/arcgis-blog\/#website","url":"https:\/\/www.esri.com\/arcgis-blog\/","name":"ArcGIS Blog","description":"Get insider info from Esri product teams","publisher":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.esri.com\/arcgis-blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.esri.com\/arcgis-blog\/#organization","name":"Esri","url":"https:\/\/www.esri.com\/arcgis-blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/04\/Esri.png","contentUrl":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/04\/Esri.png","width":400,"height":400,"caption":"Esri"},"image":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/esrigis\/","https:\/\/x.com\/ESRI","https:\/\/www.linkedin.com\/company\/5311\/"]},{"@type":"Person","@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/65ee270a38fca7d22f4cecc04dded9f2","name":"Joanna Nishimura","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/image\/","url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/thumbnail2-213x200.jpg","contentUrl":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/thumbnail2-213x200.jpg","caption":"Joanna Nishimura"},"description":"Joanna Nishimura is a Product Engineer on the Real-Time Visualization and Analytics team at Esri. In her free time, you can find Joanna enjoying the great outdoors.","url":""}]}},"text_date":"September 16, 2024","author_name":"Joanna Nishimura","author_page":false,"custom_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2024\/09\/WIDE_VelocityStream_1920x1080-1.png","primary_product":"ArcGIS Velocity","tag_data":[{"term_id":538822,"name":"IoT","slug":"iot","term_group":0,"term_taxonomy_id":538822,"taxonomy":"post_tag","description":"","parent":0,"count":7,"filter":"raw"},{"term_id":221062,"name":"Location intelligence","slug":"location-intelligence","term_group":0,"term_taxonomy_id":221062,"taxonomy":"post_tag","description":"","parent":0,"count":12,"filter":"raw"},{"term_id":757411,"name":"real-time analytics","slug":"real-time-analytics","term_group":0,"term_taxonomy_id":757411,"taxonomy":"post_tag","description":"","parent":0,"count":5,"filter":"raw"},{"term_id":776592,"name":"real-time data monitoring","slug":"real-time-data-monitoring","term_group":0,"term_taxonomy_id":776592,"taxonomy":"post_tag","description":"","parent":0,"count":1,"filter":"raw"},{"term_id":521922,"name":"real-time visualization","slug":"real-time-visualization","term_group":0,"term_taxonomy_id":521922,"taxonomy":"post_tag","description":"","parent":0,"count":4,"filter":"raw"}],"category_data":[{"term_id":777102,"name":"Arcade","slug":"arcade","term_group":0,"term_taxonomy_id":777102,"taxonomy":"category","description":"","parent":0,"count":98,"filter":"raw"},{"term_id":37121,"name":"Real-Time Visualization &amp; Analytics","slug":"real-time","term_group":0,"term_taxonomy_id":37121,"taxonomy":"category","description":"","parent":0,"count":166,"filter":"raw"}],"product_data":[{"term_id":756702,"name":"ArcGIS Velocity","slug":"arcgis-velocity","term_group":0,"term_taxonomy_id":756702,"taxonomy":"product","description":"","parent":36981,"count":61,"filter":"raw"}],"primary_product_link":"https:\/\/www.esri.com\/arcgis-blog\/?s=#&products=arcgis-velocity","_links":{"self":[{"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/blog\/2481792","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/blog"}],"about":[{"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/types\/blog"}],"author":[{"embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/users\/361042"}],"replies":[{"embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/comments?post=2481792"}],"version-history":[{"count":0,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/blog\/2481792\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/media?parent=2481792"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/categories?post=2481792"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/tags?post=2481792"},{"taxonomy":"industry","embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/industry?post=2481792"},{"taxonomy":"product","embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/product?post=2481792"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}