Tagged: GoogleMaps

A new round of trip history data has been made public by Capital Bikeshare. I’ve created a new version of the CaBi Trip Visualizer for the 4th Quarter of 2012, covering October through December. Use the tool to analyze travel patterns for people using the bikeshare system.

475,736 trips were made in the 4th quarter. The bikesharing usage is highly seasonal, as ridership went down 25% from the 3rd quarter (the summer months: July, August and September). But compared to 2011’s 4th quarter, ridership is up 52%. Broken down by membership types, the number of rides by registered users went up 54%, and the number of rides by casual users went up 40%. Registered users are those who buy memberships for 1 month or 1 year; casual users buy memberships for 1 day or 5 days. » Continue Reading…

dccabiI love biking and mapping, so any chance to play with geo-spatial bike data usually results in a new little bike-data-mapping application. My latest analytical tool was made using Capital Bikeshare‘s data for the Washington, DC region. The CaBi Trip Visualizer uses the data from 2012’s 3rd quarter (the most recently-available) to create an interactive map. When you select a station, arrows point to the stations that most trips go to or come from. (See A Closer Look at Bikeshare Data for more details, and Looking at CaBi Stats with a Bubble Map for a different method of visual analysis.)

Hovering over an arrow or the station it points to displays a window showing the trips made between the two stations. The difference between the two directions is the “unbalancedness,” also shown as a percent of the total.

bostonhubwayI wanted to see how challenging it would be to adjust the program for bike-sharing systems in other cites, though Capital Bikeshare is the only one I’ve ever used. I looked at web sites for Paris’s VĂ©lib’, London’s Barclays Cycle Hire, and Denver B-cycle, but couldn’t find any links for open data.

Boston’s Hubway doesn’t post trip data on their web site, but the Hubway Data Visualization Challenge made available data from a 14-month period (July 28, 2011 to October 1, 2012). Though the contest has ended, I created my Hubway Trip Visualizer. » Continue Reading…

wordwhereHere’s a fun tool that lets you create your own heat maps of words: WordWhere. Choose any geographic location and see where words tend to cluster. The search is made against Flickr’s gigantic collection of geotagged words, searching the photos’ titles, descriptions and tags.

The program’s strength is in finding geographic locations, such as searching for “Boston” or “Chicago.” Searching for larger areas, like “Canada,” will focus on populated areas where people are posting geo-tagged photos. You can also get reasonable responses for things like “beach,” “alligator,” or “rodeo.” Words not associated with regions tend to be dominated by the heavily-populated areas, though it is still fun to search more-abstract words.

The program uses treemapping, basically a binary search. It keeps dividing a portion of the map into halves, trying to figure out where the biggest results are. You can see the map being updated as the map is divided into smaller rectangles. You can control how many divisions should be made. The greater the density of words, the pinker that rectangle will appear. » Continue Reading…

Where Do Words Appear?

Yelp MapperI’m testing using the Yelp API to populate a custom map, powered by the Google Maps API. The program is the Yelp Mapper. It’s a full-screen map that lets you show markers for businesses and such. The field in the lower-left-hand corner lets you enter any description of a place. This goes to the Google geocoding API, which determines where to move the map to. State codes and ZIP codes work well here.

The next field lets you search for Yelp entries. The search is matched against the business name, category, and user comments. Every search you make is layered on top of the previous matches, unless you hit the clear button.

The goal of the program is to create a version of the bike-shops map which gets its data dynamically. (See Updating the Bike Shops Map.) This version is much more powerful because both the location and the subject are dynamically chosen by the user. However, the tradeoff is that you lose some precision. You’ll find the Yelp searches turn up a lot of unintended results. It’s nice to have a curated map, but impractical to scale up for a larger audience. » Continue Reading…

Mashup of Yelp and Google Maps

modesGoogle maps gives you four options for showing directions: by car, by public transit, walking, and bicycling. My Side-by-Side Router shows all four at the same time.

Enter your starting and ending points. You can enter a specific address or any description that Google’s geocoder can figure out. The four routes are shown in different colors (in some cases they will overlap). Use the “steps” buttons to show pins at each step; clicking on the pins will show the specific directions for that step. Some cities will not have any transit information.

The screen also shows the estimated travel time and distance for each mode.

For quick demos, change the “anyplace” drop-down menu to a given town, for quick location choices. » Continue Reading…

It’s great when companies like Capital Bikeshare make their data available. On their Trip History Data page they have stats for each quarter. I downloaded the most recent one, for 4th Quarter 2011, and created an interactive bubble map, trips4q2011.html, to illustrate the statistics.

The map is based on the one I created for Metro data (see Showing Metro Trips with a Bubble Map), but with expanded functionality. The CaBi data lets you specify registered users or casual users. A control at the bottom let you magnify the size of the circles used. At 1x magnification, a single trip is represented with a circle with a radius of 25 meters (an area of just under 2,000 square meters). Select stations with the drop-down menu or by hovering over it.

The list button will present a textual list of the data, sorting the station in descending order. The compare checkbox lets you compare two sets of values. In overlap mode you can manipulate a second set of bubbles, blue rather than red. The sum and difference modes compare the two sets, displaying the results in a single color.

The program was developed using JavaScript and the Google Maps JavaScript API v3.

The Bike Shops and Beyond map was created just over 4 weeks ago, but was already due for an update. Bicycle Space has moved to a new location, 8 Capital Bikeshare stations have been added, and I added a bunch of shops that had been missing. Though the map purports to represent only Washington, D.C. and Arlington, Virginia, I added more places around the region’s perimeter. (See Mapping Bike Shops, and Beyond.)

To support the map’s bike-friendly theme, I used a bike-oriented map. This was done by using the Layers feature of the Google Maps JavaScript API. The Bicycling Layer is drawn on top of the traditional Google map types (including the satellite view), and displays bike lanes and suggested bike routes. I do not have a bike layer for the OpenStreetMaps view. » Continue Reading…

This interactive bubble map lets you study travel patterns, showing results from the 2007 Survey of Metro Passenger Origin and Destination Stations. The survey got results from 708,406 passengers, asking them their origin and destination. I obtained a spreadsheet of the responses, but it’s hard to analyze a table of numbers with 86 rows and 86 columns. So, I decided to create a map using bubbles to reflect the volume of traffic. Yes, the data is five years old, but it’s all I had available.

When you move your cursor over a station, red bubbles appear over the other stations, their size reflecting the number of trips that originated at those stations that ended at the one you selected. An option at the bottom lets you see the reverse: trips from your selection to each of the remaining stations (using orange bubbles). You can also select a station via the menu at the bottom. Your chosen station is given a blue bubble showing the total. To view the exact numbers, click the “list” button. Your screen may not be tall enough to view all entries. (Hit the enter key to continue.)

To implement this, I first investigated Google Fusion Tables, but grew frustrated with the limited interface in their beta release. I found greater success with the Google Maps JavaScript API V3, which I have already used on other projects.

I built KML to show a day in the life of Metro, but to view KML you need a program like Google Earth. So, it was time to figure out a way to show the same data directly in the browser. A good alternative is the Google Maps JavaScript API V3. Instead of describing lines, stations and trains in KML tags, I used JavaScript to control the map display. All this is contained in regular HTML.

There are three models of Metro:

» Continue Reading…

Here’s my application for discovering Capital Bikeshare (CaBi) locations, and the availability of bikes and empty docks. I was inspired to build CaBi Mapper after the Bike Shops and Beyond project, which was populated with coordinates for a variety of businesses and services, including CaBi locations.

The data came from Capital Bikeshare‘s bikeStations.xml file, which is constantly updated as bikes are checked out and returned. It includes latitude and longitude, so mapping is easy. PHP lets you read in the entire XML file with a single function, simplexml_load_file. I used the Google Maps JavaScript API v3 to draw the map (with help from OpenStreetMap).

Once the data is available, the rest of the project is designing the user interface. I chose to go with pie charts to show the ratio of available bikes to empty dock slots. Red (matching the color of the bicycles) is used to represent available bikes, and dark blue represents free spaces. Hovering over a marker displays the exact number of bikes and slots, as well as the location. Clicking on the marker will zoom in and pan to the center, and display an information window with the location, availability statistics, and the date and time that a change was last reported, meaning the last time a bike was either taken or returned. » Continue Reading…