liveBook · Manning

Tourist arrivals

As explained in Data Storytelling with Altair and AI

Tourist arrivals are recorded entries or visits by tourists to a destination or accommodation establishment during a specified period.

Tourist arrivals measure the number of arrivals at tourist accommodation establishments over a specified period. As a time series, they can help assess whether visitor demand is rising and whether a proposed hotel investment is supported by a broader tourism trend. A hotel considering a new swimming pool, for example, can compare Portugal’s arrivals with those of France, Italy, Germany, Spain, and the United Kingdom rather than treating one hotel’s recent experience as sufficient evidence. Arrivals alone do not settle the investment decision: pool popularity, construction cost, and potential revenue also matter. section 2.2

The data consists of dated arrival counts for several countries, with values spanning the 1990s through 2019. Before comparing annual totals, inspect coverage: some country-year combinations are missing, and 2019 ends in October. Summing an incomplete year can create a misleading comparison. For a progressively growing series with seasonal variation, limit the comparison to years available across the analysis, here 1994–2018, before aggregating monthly arrivals into yearly totals. section 2.2.1 section 2.3.1

Table 2.1 Arrivals at tourist arrivals establishments since 1994
Date
IT
FR
DE
PT
ES
UK
1990-01-01
2,543,920
3,185,877
325,138
1723,786
1,776,000
1990-02-01
2,871,632
3,588,879
381,539
1,885,718
2,250,000
1990-03-01
3,774,702
4,272,437
493,957
2,337,847
2,662,000
…
…
…
…
…
…
…
2019-08-01
11,649,500
13,692,822
14,570,339
2,531,809
12,893,366
8,889,049
2019-09-01
9,888,817
11,684,845
14,373,815
2,263,748
5,858,984
2019-10-01
7,692,388
10,401,793
13,780,441
1,995,942
7,455,781

The table makes the metric concrete: each Date row supplies arrival counts for country columns. It also shows why a date-aware comparison is necessary: values occur monthly, and the final displayed year does not necessarily contain every month. section 2.2.1

A practical path from arrival counts to a decision-relevant comparison is:

  • Load the data with Date parsed as a date, then reshape country columns into Country and Tourist Arrivals fields so one chart can encode each country consistently. section 2.2.1 section 2.3.1
  • Draw a raw line chart with date on the x-axis, tourist arrivals on the y-axis, and country as color. This exposes the overall upward movement, but overlapping lines make detailed comparison difficult. section 2.3.1
  • Extract the year, remove boundary years with incomplete coverage, and sum arrivals by Year and Country. The resulting annual series compares like with like. section 2.3.1
  • Calculate each country’s percentage increase from its 1994 total. A shared percentage baseline shifts attention from differing absolute sizes to relative growth. section 2.3.1
  • Highlight Portugal with a thicker line and annotate 2018 values. The chart then foregrounds the question relevant to the hotel while retaining international context. section 2.3.1

Comparing Portugal with broader trends

A raw multi-country chart suggests that tourist arrivals increased across all displayed trend lines from 1990 onward. That is encouraging, but it is not yet a reliable annual comparison because early values are absent for some countries and 2019 is partial. Restricting the data to 1994–2018, summing arrivals within each year, and plotting percentage increase since 1994 produces a clearer view of Portugal’s trajectory relative to peer countries. This turns a general impression of growth into an audience-focused visual argument for further investment analysis. section 2.3.1

How Data Storytelling with Altair and AI covers it

How deep it goes
Works through loading, reshaping, filtering incomplete years, annual aggregation, percentage change, highlighting, and annotation.
Examples
Uses monthly country counts for Portugal, France, Italy, Germany, Spain, and the United Kingdom, plus a hotel swimming-pool decision.
What it assumes
Assumes a practical analysis goal while demonstrating date parsing, reshaping, filtering, grouping, and chart encoding.
What you can do after
Apply it via pandas and Altair to produce a coverage-aware annual comparison of tourist-arrival growth.
How it connects
Connects tourist arrivals to time series, missing values, data aggregation, percentage increase, pandas, and Altair.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Data Storytelling with Altair and AI. The section links point to the parts of the book it draws on.