Get Supply Shocks
get_supply_shocksDetect abnormal collapses in trade volumes ("sudden volume changes"). Flags periods where a partner/product pair's volume drops well below its historical average (>2 sigma by default). Returns ranked shock events per flow, each with timeline phases (baseline, decline, disruption, recovery, ...), magnitude, abnormality score and underlying series.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | The product/reporter/partner-set/period/frequency slice to query -- the same request body every tradedashboard.eu analytical endpoint takes. See its own field descriptions (product, reporter, partner_set, period_start, period_end, frequency, n_top, ...) for details; only `product` is required, everything else has a sensible default. | |
| compact | No | If true, condense long numeric time series (more than ~6 points -- typically monthly/quarterly windows or wide multi-partner/multi-period breakdowns) into summary statistics (first, last, min, max, mean, pct_change) instead of returning every data point. Leave false for full-fidelity series (e.g. to actually plot a chart); set true when you just need the headline trend and want to save context. | |
| entity_level | No | Dimension to analyse. 'partner' -- how concentrated/volatile is the reporter's trade across its trading partners? 'reporter' -- how concentrated/volatile is a given partner's trade across EU member states? When 'reporter', 'partner_name' is required. | partner |
| partner_name | No | Partner country name (English). Required when entity_level='reporter'. | |
| min_abnormality | No | Minimum statistical abnormality of the volume crash, in sigma. Lower = more (weaker) shocks flagged. | |
| cumulative_share | No | Only the top trading partners that together account for this share of total trade are analysed. | |
| min_active_years | No | Consecutive years of regular trade required before a collapse can be flagged. | |
| max_tolerated_gap | No | Consecutive quiet periods allowed within an otherwise stable trading relationship. | |
| relative_threshold | No | Minimum drop relative to peak volume to count as a collapse (0.10 = 10% drop). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||