6. Trends
All statistics are calculated in the local time without shifts for daylight saving time of the station where the data originated from.
Daily aggregates will report the trend in ppbv/day and monthly aggregates will report the trend in ppbv/month.
https://toar-data.fz-juelich.de/api/v2/analysis/trends/[?QUERY-OPTIONS]
where QUERY-OPTIONS are:
any combination of query options from both TOARDB REST interface - 2.4 Stationmeta and TOARDB REST interface - 2.5 Timeseries
daterange = <list of two datetimes: date range for which to extract data>
flags = <list of strings: only select data points with the specified quality flags> (for a description of flags and all available flag names see User Guide - 5.2 Data Quality Flags)
sampling = <string: temporal aggregation to use> (daily|monthly)
statistics = <list of strings: statistics to calculate> (for available values and details see 5.2. Available Statistics )
seasons = <list of strings: seasons to use for seasonal aggregations> (for available values see SEASON_DICT) (default: “DJF,MAM,JJA,SON”)
crops = <list of strings: crops to use for vegseason aggregations> (for available values see ALLOWED_CROPS_VALUES) (default: “wheat,rice”)
min_data_capture = <number: minimal fraction of available hourly values in the aggregation interval to report an aggregated value, must be between 0 and 1> (default: 0.75)
method = <string: regression analysis method to use> (OLS|quant) (default: quant)
quantiles = <list of numbers: quantiles to use when using quantile regression, must be between 0 and 1>
num_samples = <number: number of sampled trends in moving block bootstrap> (default: 50)
metadata_scheme = <string: select how much metadata is returned> (basic|extended|full) (default: full)
format = <string> (json_simple|by_stat_quant) (for details on the formats see Reference 8. Aggregated Output Formats )(default: json_simple)
Response: The query will return a unique task identifier and a link to check the status of your query.
Example: https://toar-data.fz-juelich.de/api/v2/analysis/trends/?country=DE&variable_id=5&limit=3&daterange=2010-01-01T00:00:00,2020-12-31T23:59:59&flags=AllOK&sampling=monthly&statistics=avgdma8epax,dma8eu&quantiles=0.25,0.5,0.75
Result: {“task_id”:”24666af1-5a51-4223-b8fc-c7d2d5f0070e”,”status”:”https://toar-data.fz-juelich.de/api/v2/analysis/status/24666af1-5a51-4223-b8fc-c7d2d5f0070e”}
To retrieve the result send a request to the status endpoint with your task identifier. If the result is there you will be redirected. The result will be a zip archive containing files in the format you have chosen.