“Projection”, it’s a glorious word that can refer to many things. It can refer to the way in which a rapper was brought back from the dead at a concert. It can refer to the cause of the anger you feel when you watch someone go into a career in software rather than the far more lucrative field of alpaca farming. It can even refer to the way adorable shadow puppets are cast onto a wall. In the case of Yellowfin’s Business Intelligence solution, sadly, it is only used in one context – cartographic projection for mapping. In this blog I will attempt to take you through what it is, and why you should care.
So what is it?
If you look at a picture of the earth with lines of latitude and longitude (such as my lovingly hand-rendered example below) you will see that although lines of latitude (horizontal) run parallel to each other, lines of longitude (vertical) converge at the north and south poles. This means that when a map is displayed on a flat, two dimensional surface (such as a Yellowfin chart), points north and south of the equator become more and more stretched.
It is impossible to display a sphere on a flat surface without distorting it. A projection refers to the method in which the sphere is converted to be displayed on a flat surface. Essentially, it’s choosing the way in which the geometry will be distorted.
Usually it’s sufficient to display data using ‘flat’ projection – where longitude and latitude are converted directly to X and Y coordinates. However, for various reasons this may not be desirable. Different projections may simply look better for a given purpose. Or, if you’re displaying a map of a relatively small area (such as Australia), a different projection may do a better job of preserving spatial relationships. The below picture of Australia, created using the popular Mercator projection (left), is depicted next to a flat projected picture of Australia (right). Note that the flat projected version is more stretched out. This becomes more pronounced the further south you get.
If you’re wondering why anyone would chose to use a projection other than Mercator, as it does such a good job of making Australia look pretty, take a look at Google Maps and note that Greenland appears to be bigger than Africa. This is an example of the distortion caused by Mercator, and it’s arguably a worse choice than flat projection for large scale mapping.
But how does it affect me?
There are two times in your Yellowfin-using life that projections may affect you.
The first is when you’re sourcing your geometry data. If you’re purchasing data, it’s likely you’ll be given the option to choose how it’s projected.
The second, and certainly more visible, way is when you’re connecting to a WMS server. When selecting a layer, there’s a drop-down titled “SRS”, which may contain a number of codes.
SRS stands for “Spatial Reference System”. Each code within the drop-down represents a different type of projection. In the above example, “EPSG:4326” is actually a flat projection.
Occasionally, people have problems with WMS layers not being displayed on their GIS reports. This is often because their data and WMS layer are using different projections. The most important thing to do, if given the opportunity to choose the projection of your data, is to make sure it’s projected in a way that’s supported by any WMS server you’re planning to use.
And what do you suggest using?
Usually it’s preferable to use flat projection. Most geometry data you’ll find on your travels is flat projected, and most WMS servers support EPSG:4326. While Google Maps are displayed using a form of Mercator projection, Yellowfin still expects data to be flat projected to display correctly on a Google Map.
So that’s projection in terms of Yellowfin – the only type of projection we know. At least until 9.2 when my development roadmap suggests we will begin supporting shadow puppet charts.
Here’s a sample of what one will look like… it’s a bunny!