Web Mapping Quickstart
Welcome Back
Two weeks ago: Session 1
Web mapping platforms and projects
Last week: Session 2
Web mapping from scratch
This week: Session 3
Advanced web mapping
In print cartography, there are dozens of map types:
Reference Maps
Wayfinding
Transit
Navigation
Topographic
Thematic Maps
We are entering the GOLDEN AGE of web mapping:
There are libraries and APIs and tutorials to help you translate these map types to the web.
... (but only a subset of these are easy with out-of-the box tools)
Historically web mapping has evolved without much cartographic theory...
There was Google and then there were mashups
HousingMaps.com, by Paul Rademacher, 2005
... which led to an explosion in special thematic maps
... and also this question in the minds of many cartographers:
Are web maps and print maps homologous or analagous?
I am not fond of heat maps.
The term 'heatmap' is imprecise. Isopleth? Point density? Interpolation?
On the web it usually means kernel density and usually just shows population density
Where the points are sparse or coincident, kernel density generates a meaningless blur:
Common Js libraries that generate 'heatmaps' dynamically use zoom level as a proxy for kernel size, which makes no sense analytically.
The default color scheme is horrid (nicknames: "Tacky Angry Rainbow" and "Angry Fruit Salad").
Tacky Angry Rainbow
Tacky Angry Rainbow
Angry Fruit Salad
Angry Fruit Salad
They arise from demand from people who don't know what they are doing, but know they want to show a lot of points on a map.
Alternative: clustering
Entirely different although it looks similar: dot density maps
Someone clever putting a lot of points on maps quite artfully: Eric Fischer
In general all of these examples follow certain slippy map and mashup paradigms, which we talked about last time.
The hottest other option right now is D3.
D3 is a Javascript library built for data visualization.
In all the best and worst ways:
D3
IS
IN
SANE
If you want to learn D3, Scott Murray who teaches at USF has some great resources.
I also like DashingD3js.com
...there are other mapping libraries out there that can handle different projections, distortions, and animations... plus whatever else you want to do.
We should still strive for sound cartography in mashups.
A few high level concepts from cartography, which is a visual enterprise:
1. Visual variables
2. Visual hierarchy
BAD


GOOD
3. Visual argument
An important concept for web cartography is "screen real-estate"
Slippy map is a way around all of this but.... for some maps it is overkill & potentially a cop-out.
The main thing the web brings to cartography is interactivity, which can take many forms.
In web design and development, people make entire careers out of designing for interactivity. The field is called UI/UX, which is shorthand for user interface and user experience.
It means you think through how people who visit your site will interact with it, and you design the interface to guide the user toward the experience you want them to have.
UI/UX is a really important component of web mapping.
Project managers creating government web portals for geospatial data, I am talking to you.
For this reason, while it makes sense in print cartography to talk about map readers, in web cartography we talk about map users.
In our first session, we saw some forms of interactivity that are standard in out of the box tools.
Panning & Zooming
Info Boxes
Tooltips
Highlighting
Charts
Embedded images/video
Geocode box
"Zoom to my location" button
Animation
All these whizz-bangs are neato!
Let's play with a web map: In Chrome go to: leafletjs.com/examples/mobile.html
Click on Menu > Tools > View Source & copy/paste all the text you see into a text editor.
File > Save As > mobile.html
(remember where you save it!)
This tutorial uses a function from the Leaflet library to zoom to your approximate location.
To make it work, you probably need a web server running.
If you are on a mac or a Windows or Linux machine with Python installed and globally available, type:
python -m SimpleHTTPServer
Type "localhost:8000" into an new browser window & navigate to where you saved mobile.html
We'll go through it chunk by chunk.
Can you figure out how to switch the basemap to the Stamen toner tiles we used last week?
CartoCSS
For example:
CartoCSS is based on CSS. Some things to understand:
Thanks everyone! See you on the interwebs: @mizmay....
Presentation made with big