Hydro Explorer: An interactive web app to investigate changes in runoff timing and runoff seasonality all over the world

Climatic changes and anthropogenic modifications of the river basin or river network have the potential to fundamentally alter river runoff. In the framework of this study, we aim to analyze and present historic changes in runoff timing and runoff seasonality observed at river gauges all over the world. In this regard, we develop the Hydro Explorer, an interactive web app, which enables the investigation of >7,000 daily resolution discharge time series from the Global Runoff Data Centre (GRDC). The interactive nature of the developed web app allows for a quick comparison of gauges, regions, methods, and time frames. We illustrate the available analytical tools by investigating changes in runoff timing and runoff seasonality in the Rhine River Basin. Since we provide the source code of the application, existing analytical approaches can be modified, new methods added, and the tool framework can be re‐used to visualize other data sets.


| INTRODUCTION
Rivers are important lifelines nourishing communities along their shores. Their waters inter alia are used for drinking, irrigation, energy production, industry, and transportation. Any change in the total amount or seasonal distribution of water potentially has serious consequences. Human livelihood often is directly linked to the water level. Hence, it is crucial to detect changes in river runoff and identify underlying driving mechanisms. Discharge is measured at a large number of gauging stations all over the world. However, it often remains rather difficult to access the data and to quantify possible changes. In addition, as important as the detection of changes, is the presentation of results in an easily accessible way for parties in-and outside the scientific community. This is particularly difficult for larger data sets covering multiple river basins on different continents.
In recent years, the potential of interactive web tools to share information is increasingly recognized and used by the scientific community. Scientifically engineered online tools support a very broad spectrum of objectives including data distribution (Moghadas, Schaaf, Gerwin, Badorreck, & Hüttl, 2019), the analysis of data (Brendel, Dymond, & Aguilar, 2019;McMurdie & Holmes, 2014), drought monitoring (Zink et al., 2016), teaching statistics (Doi, Potter, Wong, Alcaraz, Chi, et al., 2016), data mining (Dunning et al., 2017) or the evaluation and selection of climate model ensembles (Parding et al., 2020). Often, the open-source programming language R and the R package "Shiny" are used to develop interactive web content. R fosters open and reproducible science and software is ideally suited to be re-used, customized, and refined (Slater et al., 2019).
In this perspective, the main object of this study is the development of the Hydro Explorer, an interactive Shiny web application that enables the investigation of runoff time series from all over the world in terms of changes in runoff timing and runoff seasonality. Changes in timing or the seasonal distribution of runoff are excellent indicators of impacts of climate change or modifications of the river network or watershed (Brunner, Melsen, Newman, Wood, & Clark, 2020;Kormann, Francke, Renner, & Bronstert, 2015;Rottler, Francke, Bürger, & Bronstert, 2020;Schwartz, Hall, Sun, Walton, & Berg, 2017;Stewart, Cayan, & Dettinger, 2004). We aim to provide an interactive tool that can be used in-and outside the scientific community to explore, learn, teach, and communicate topics related to streamflow, ensure easy accessibility and re-usability, allow the testing of parameter sensitivity of analytical tools, and enable a straightforward comparison between analytical tools, river gauges, regions, and time frames. Here, we present the analytical tools available and illustrate the functionality of the web application by investigating selected gauging station from the Rhine River Basin in Central Europe.

| RUNOFF DATA
In the framework of this study, we focus on the global runoff data set from the Global Runoff Data Centre (GRDC). GRDC was established in 1988 and is operating under the patronage of the World Meteorological Organization (WMO) to foster research on global and climate change. Their unique collection of discharge time series comprises daily resolution runoff data from more than 7,000 gauging stations from all over the world and represents a key data set for hydrological research. The length of the stored discharge series varies and ranges from a couple of years to more than 200 years. Most time series are available for Europe and North America (Figure 1). Updates to GRDC come with delays and frequencies vary among contributing agencies.
Therefore, fewer observations are available in recent years. The daily resolution discharge data used in the following analysis was provided by GRDC May 2019.

| ARCHITECTURE AND IMPLEMENTATION
The web app was implemented based on the R package "Shiny," which offers a framework for web application development in R (Chang, Cheng, Allaire, Xie, & McPherson, 2019;Slater et al., 2019). The core of the Hydro Explorer consists of the typical two-file structure of a Shiny web app (Figure 2). One R-file defines the layout and the appearance of the web app (ui.R) and another one contains all computational instructions (server.R). The Hydro Explorer is part of the R package "meltimr." The open-source R package "meltimr" including detailed instructions how to install and test the functionality is available at https://github. com/ERottler/meltimr. All functions the Hydro Explorer needs are incorporated in this R package. We chose this set-up to enable easy sharing and installation of the programme code. Existing tools can be easily modified and new analytical approaches added. All analytical tools also can be used outside the web app environment.
As a first step in order to use the web app, a table containing meta information about all discharge time series located in the data folder (e.g., station name, gauge location, and file path) needs to be compiled ( Figure 2). This only has to be done once, before the first start of the web app (see file grdc_meta.R). The GRDC discharge data are imported in a later step following the interaction with the user interface. The separation of the database from the web app enables the re-use of the web app with a different set of GRDC runoff data, facilitates the incorporation of additional data sources and keeps required working memory at a minimum. To host the web app online, the installation of a shiny web server is necessary. An example instance of the Hydro Explorer is available at http://natriskchange.ad.
umwelt.uni-potsdam.de:3838/HydroExplorer/. Resources needed to host the web app are low. A web server with one central processing F I G U R E 1 Availability of GRDC daily resolution discharge time series by year and continent (status as of May 2019) F I G U R E 2 Architecture and implementation of the Shiny web application Hydro Explorer [Color figure can be viewed at wileyonlinelibrary.com] unit (CPU) and one gigabyte (GB) of working memory is sufficient, but may need to be extended if larger traffic, that is, multiple parallel users, is expected.

| ANALYTICAL TOOLS
In the following, we present the selection of analytical tools available within the Hydro Explorer. The presented tools enable the investigation of daily resolution discharge time series with regard to changes in runoff timing and runoff seasonality. Figure 3 presents the user interface of the Hydro Explorer. Figure 4 depicts the analytical tools and plot types.

| Raster graph
A raster graph is a three-dimensional surface plot, where the x-axis is the day of the year, the y-axis the individual years and the z-axis the daily value of the investigated variable (e.g., streamflow, temperature, or snow depth). The visualization of the data using raster graphs provides a quick first insight into the dynamics and processes controlling investigated variable at the selected site (Koehler, 2004;Strandhagen, Marcus, & Meacham, 2006). This visualization tool enables the display of inter-and intra-annual variability in one single figure. A similar visualization technique is used in Kormann et al. (2015) to display intraannual and elevation-dependent signals in trends in alpine hydroclimatological data. Within the web app, the time frame displayed and the start day of the (hydrological) year (e.g., 1 October or 1 November) can be selected.

| Mean graph
Mean annual cycles (or mean annual hydrographs) provide a very good first insight into runoff seasonality, for example, due to the build-up and melt of seasonal snow packs. The Mean graph tool displays mean annual cycles for two selected time frames. Vertical lines mark days of the year of the annual maximum value. The time lag between the days of maximum runoff of the two selected time frames is noted top right ( Figure 4). The two time frames compared can be varied. In addition, a moving average window can be applied to the time series and its impact on the annual cycles studied.

| Volume timing
A frequently applied approach to investigate the timing of (snowmelt) runoff is the determination of the day of the year (DOY) a certain fraction of the total annual volume passes a discharge gauging station (e.g., Déry et al., 2009;Maurer, Stewart, Bonfils, Duffy, & Cayan, 2007;Stewart et al., 2004;Stewart, Cayan, & Dettinger, 2005). The Volume timing tool displays the DOYs when 25/50/75% of the total annual runoff was recorded. On top of the panel, mean DOY and a Theil-Sen estimate of the linear trend are noted for each volume fraction (Bronaugh & Werner, 2013;Sen, 1968;Theil, 1950). The start day of the year (e.g., 1 October or 1 November) can be modified interactively within the web app. Furthermore, the time frame investigated can be varied.
Two plot options are available: "Line plot" and "Image plot." For the selection "Line plot," quantiles values of individual probability levels (e.g., 0.75 or 0.90) for two selected time frames are compared. The "Image plot" option shows the difference in quantile values between the two selected time frames for all probability levels, that is, 0.01-0.99 sorted along the y-axis.

| Further options
River gauging stations can be filtered according to data availability and location (see option Filter stations). Furthermore, watershed boundaries derived based on the HydroSHEDS drainage network (Lehner, 2012) can be visualized via the layer control on the bottom left ( Figure 3). A short summary, a description of the analytical tools, information about the data and code availability, and contact information also are included into the web app (Figure 3).

| EXAMPLE OF USE
In the following, we illustrate the functionality of the analytical tools using examples from the Rhine River Basin ( Figure 5 and Table 1). The Rhine River stretches from the European Alps in the south to the North Sea and is the second largest river in Central Europe (Belz et al., 2007;Middelkoop et al., 2001;Stahl et al., 2016). Snow and glacier melt dominate runoff in the Alpine part of the basin, rainfallrunoff processes dominate the runoff regimes of important tributaries  (Belz et al., 2007;Stahl et al., 2016). Time frame investigated, that is, 1919 to 2016, corresponds to the maximum common time period of selected river gauges.

| Raster graph
We use the raster graph tool to investigate the runoff seasonality at the two Swiss gauges Diepoldsau and Gsteig ( Figure 5). Gauge Diepoldsau is located at the Alpine Rhine just upstream Lake Constance, Gsteig gauging station is located in the southern part of the Aare River. In the Alpine Rhine Basin, numerous large reservoir lakes for hydropower have been constructed since the 1960s (Bosshard et al., 2013;Wildenhahn & Klaholz, 1996). There are no large reservoir lakes for hydropower production upstream gauge Gsteig. At both gauges, the raster graphs hint at a strong runoff seasonality with low/high runoff during winter/summer (Figure 6a,b). River runoff at gauges Diepoldsau and Gsteig seems to be dominated by the buildup and melt of a seasonal alpine snow cover. Furthermore, a diagonal pattern is imprinted at gauge Diepoldsau since the 1960s. This is a typical signal of high-head hydropower generation with reservoir lakes (e.g., Meile consumption and hydropower production, more runoff is recorded during the week compared to the weekend. As the days of the weeks shift over time, a diagonal pattern shows up in the raster graph. The example presented shows that the visualization of discharge time series as raster graph is well suitable to get a first quick insight into important runoff characteristics.

| Volume timing
We also use the two Swiss gauges Diepoldsau and Gsteig to illustrate the functionality of the analytical tool Volume timing. At gauge Diepoldsau, the timing of the annual runoff fractions shifts toward the beginning of the hydrological year (Figure 6c). The first 25% of discharge are recorded more than 60 days earlier. The DOY recording the center of volume, that is, 50% of the annual runoff, occurs almost 20 days earlier. We attribute detected changes at gauge Diepoldsau mainly to the construction and operation of reservoirs, as hydropower production using large reservoir lakes redistributes runoff from summer to winter (Belz et al., 2007;Bosshard et al., 2013;Verbunt, Zwaaftink, & Gurtz, 2005). In contrast, for gauge Gsteig, which has no large reservoir lakes for hydropower production upstream, linear trend estimates hint at little to no changes in the timing of runoff fractions (Figure 6d). The investigation of annual runoff fractions (e.g., centre of volume) can give a good insight into changes in the seasonal redistribution of water. However, caution has to be exercised interpreting changes, as the sensitivity of this indicator can vary across the year and be influenced by other flow components (Whitfield, 2013).

| Annual maxima
In order to introduce the analytical tool Annual Max, we investigate the timing of runoff maxima observed at gauge Diepoldsau and Gsteig. We compare changes in the timing of annual runoff maxima (determined between January and December) with changes in the timing of runoff maxima determined between January and August.

| Percentile graph
In order to illustrate the functionality of the analytical tool Percentile graph, we calculate runoff quantiles for gauges Murgenthal and Emmenmatt. Gauge Murgenthal is located in the South-East of the Rhine Basin at the Aare River. At gauge Emmenmatt, runoff of the Emme River, a tributary of the Aare River, is measured ( Figure 5). We estimate quantiles empirically for the probability level 0.8 (80% of observed values are below determined threshold) on a monthly level taking all daily values into account. We compare values between the two time frames 1919-1967 and 1968-2016 (Figure 8a,b). The time frames compared represent the first and second half to the maximum common time period of all river gauges selected (Table 1).
Selecting the visualization option "Image plot" within the tool, the show up for lower probability levels. At Emmenmatt, a similar, but less pronounced signal appears. We suspect changes in precipitation characteristics to contribute to detected changes in runoff quantiles. However, also changes in snowmelt and the impact of anthropogenic modifications of the river network, for example, the numerous hydropower installations and the Jura water corrections (Bodemann & Pfammatter, 2015;Wetter et al., 2011), need to be considered. In order to pin down the underlying mechanisms causing the detected signals in river runoff, detailed analyses of precipitation and snowmelt are required.

| Mean graph
Using the analytical tool Mean graph, we compare annual cycles for the two time frames 1919-1967 and 1968-2016 and assess the impact of data aggregation prior to the calculation of mean annual cycles. The time frame 1919 to 2016 represents the maximum time period of all river gauges selected (Table 1). Gauges investigated, that is, Plochingen and Stein, are located in the catchment of the Neckar River, one of the main tributaries of the Rhine River ( Figure 5). In contrast to the runoff seasonality in Alpine catchments, the Neckar River has a pluvial runoff regime with high runoff during winter and low runoff during summer (Figure 9). Before the calculation of the mean annual cycles, we apply a 0-day, a 30-day or a 90-day moving average filter on the time series. The application of moving average filters has a strong smoothing effect on the annual cycles and affects the time lag between the maximum values of the two time frames. Furthermore, our analyses hint at more runoff in the second, more recent time window , particularly during winter. Studies investigating possible future runoff conditions in similar hydro-climatological settings hint at the possibility of a further increase in runoff, particularly during winter (e.g., Bosshard, Kotlarski, Zappa, & Schär, 2014;Menzel, Thieken, Schwandt, & Bürger, 2006;Pfister, Kwadijk, Musy, Bronstert, & Hoffmann, 2004;Wolf, 2003).

| CONCLUSION
The Shiny web app Hydro Explorer proved to be well suited to investigate large discharge data sets with regard to changes in runoff timing and runoff seasonality in an interactive way. The presented set of analytical tools enables a quick yet comprehensive investigation of daily discharge time series. We find that for the assessment of signal robustness, the ability to easily compare results of different methods, gauges, regions, and time frames is crucial. We exemplary investigate a small selection of river gauges in the Rhine River Basin. The global coverage of the underlying GRDC discharge data set enables the exploration of a great diversity of river systems ranging from arid to tropical, from natural to controlled by human activities and from small catchments of only a few square kilometers to the largest basin on the globe.
The implementation of the Hydro Explorer as a free and opensource software embedded in an R package provides access to the programme code and enables the re-usage and modification of existing structures. The software architecture facilitates the incorporation of additional data source and keeps working memory at a minimum.
The Hydro Explorer can serve as powerful tool in-and outside the scientific community to explore, learn, teach, and communicate waterrelated issues. An application and re-use of the Hydro Explorer in academic teaching at university (e.g., for demonstrating hydrological concepts), environmental research (e.g., for the assessment of changes in riverine habitats) as well as water-related industrial sectors (e.g., in hydropower production) is conceivable. Moreover, when maintained at a public server, it also opens up a low-threshold entry point for quick insights into properties of runoff regimes to private persons in riparian communities. Climatic changes and human activities can fundamentally alter river runoff. A close investigation and understanding of underlying processes is of great importance. Next steps in the development of the Hydro Explorer could be the incorporation of additional analytical tools and the application to other hydro-climatological data sets.