Have some data you’d like to map using CartoDB? This post will walk you through the process.
These instructions assume you are using the list of geocoded conference participant towns that you will find here (csv format). Just download the file to your machine.
Of course you are very welcome to use any other geocoded dataset you happen to have lying around. (If your data describes countries or street addresses but is not yet geocoded, CartoDB will – in theory – be able to handle geocoding them automatically. I hope to add a post on that sometime soon.)
- First, create an account on CartoDB (www.cartodb.com). To create an account you will need to provide a name and an email address. That’s all.
- Once you have an account and are logged in, look at the blue banner at the top – you will see your username. Use the dropdown arrow to select “Datasets”.
- Then click on the green “New Dataset” button.
- Drag your csv file over from Windows Explorer or navigate to it.
- At the bottom of the screen you will see a green “Connect Data” button – click.
- You should now see the data in “dataview”.
Want to map it?
- At the center of the blue banner on the top of the screen, click on “Map view”.
- At the lower left of the map screen you will see that CartoDB is suggesting two possible ways of looking at your data. Click on “Show”. Your choices are Heatmap or Bubble. Click on Heatmap.
- Doesn’t that look fancy? Sure does. Zoom in and out a few times to get a sense of how the heatmap changes.
- Now let’s look at the data in another way. Look at the vertical column on the right side of the screen. Click on the paintbrush icon (“wizards”).
- Use the arrows to navigate to “Bubble”. You will see that the “column” is automatically set to visualize the “latitude” field, which doesn’t make a whole lot of sense. Use the dropdown arrow to select “participants”. Now the bubble size will be determined by the number of participants from each location.
- You can play with the settings. Change the bubble radius or color or stroke type until you like the way everything looks.
- Just below the paintbrush icon click on the “infowindow” icon. This is where you control what a user will see when they click on a point on your map. I’ll toggle on “school”, “state”, and “town”. You can change the order in which they appear by resting the cursor on the label until you see the 4-arrowed icon and dragging the field up or down.
- Click anywhere on the map itself to make the editing box fold away.
Taking It Up a Notch
- Let’s pretend you are making a map of towns that sent more than one participant to the conference. You need to filter your data. Toward the bottom of the vertical editing column you will see a graph icon. Rest your cursor – the “filters” label will show up. Click on the icon.
- To filter on # of participants, select the participants column.
- Drag the slider to the right until the display reads 2.00-4.00.
- Click anywhere on the map itself to minimize the editing box.
Finish the Job
- In the upper right corner, click on “Visualize”
- Click “Create Map”
- In the bottom left you will see “Change basemap” and “Options”. Explore.
- In the upper left you will see “Add element”. Here is where you can add a map title, annotations, images, etc.
- When you are satisfied, click “Publish” in the upper right. Now you can harvest the URL or embed code for your map. That’s it!