214 countries and territories189 of 193 UN membersmonthly to 2026-09back to 1926
Documentation / Statistics / 42 of 75

Anomalies

GET/v1/stats/anomalies

Months where the figure sits well away from what trend and season predicted, scored in robust standard deviations, with the expected value beside it. 51 countries.

Intel plan and upKey requiredJSON or CSVCached until the next release
Parameters
NameTypeDescription
countryrequiredstring
query
ISO code of a country that carries this statistic (listed at /v1/countries/{iso})
e.g. JP
min_scoreoptionalnumber
query
Smallest score to return, in standard deviations (default 3)
e.g. 3
Request
# Months far from what was expected
curl "https://api.tourismapi.com/v1/stats/anomalies?country=JP" \
  -H "X-API-Key: $TOURISM_API_KEY"
Ready
Example response
{
    "meta": {
        "request_id": "req_8e45be3bae",
        "data_as_of": "2026-10-20T04:48:18Z",
        "count": 19,
        "country": "JP",
        "method": {
            "series": "Visitor arrivals to Japan from Total",
            "unit": "visitors",
            "first": "2003-01",
            "last": "2026-08",
            "months_checked": 84,
            "flagged": 19,
            "threshold_sd": 3,
            "range_fields": "lo80 holds the expected value"
        }
    },
    "data": [
        {
            "period": "2020-03",
            "score": -6.6,
            "expected": 974204.6
        },
        {
            "period": "2020-04",
            "score": -22.92,
            "expected": 860332.4
        },
        {
            "period": "2020-05",
            "score": -23.7,
            "expected": 595193.8
        }
    ]
}
Response fields
FieldTypeExample
periodstring2020-03
scorenumber-6.6
expectednumber974204.6