% brew("mds") %>
Each of the cities are positions so that the
distances between each of them approximate the
distances by road. The source of the data comes
from the eurodist
dataset,
distributed with R. We calculate the positions of
the cities using multidimensional
scaling. The cmdscale
function was
used to perform this task.
A consequence of multidimensional scaling is that distances between points are approximated and no longer represent their true distances. As a result, the distances between cities can be distorted from their true distances. Significant examples of distances which are inaccurate are Athens - Rome, and Cologne - Geneva. The visualisation that has been created demonstrates this effect by visualising the true distances between a reference city and all other cities.
To use this visualisation, simply click one of the city names on the left, or hover over one of the city labels in the plot. This will show the true distances in a table on the right. Optionally, one can use the 'Animate' option to automatically iterate through all options.
This example is an R-based re-implementation of a similar visualisation created by Simon Barthelmé at http://bl.ocks.org/4482115.
City | Distance (km) |
---|---|
Athens | |
Barcelona | |
Brussels | |
Calais | |
Cherbourg | |
Cologne | |
Copenhagen | |
Geneva | |
Gibraltar | |
Hamburg | |
Hook of Holland | |
Lisbon | |
Lyons | |
Madrid | |
Marseilles | |
Milan | |
Munich | |
Paris | |
Rome | |
Stockholm | |
Vienna |