Category: programming

I had always assumed animated GIFs would go the way of the Blink tag, but it seems their popularity continues to grow. Just like hipsters are bringing back vinyl records and beekeeping, animated GIFs are a sign of good taste. So to sate the public’s thirst for more GIFs, I created a tool to create custom GIFs using Google’s Street View images. Try Geo GIF to make your own custom images.

The Street View API is stunningly simple to use. All you have to do make an http request for an image with the parameters embedded in the URL. It’s fast and easy. I wrote a PHP proxy script to request a series of images and then stitch them together into a single animated image.

The web front-end lets you select any place on a map, and drop a pin to select the location. The Street View API will find the closest location, though if it’s too far from a street (like the middle of a block), you’ll see the standard “no image found” placeholder. » Continue Reading…

Color PickerHere’s a quick app I wrote to see which colors are being used in an image. But instead of just showing the hex value or RGB decimal values, it also tells you what the name of the color is.

My Color Picker uses the X11 color names, a list of 144 colors that you can use in CSS.

When you open the program, you’ll see a collage of the 144 color samples. You can enter the URL of any image on the Internet, which will replace the collage. As you hover over the image, the program will match the current pixel to the nearest color in the X11 palette. If there isn’t an exact match, it’ll show the nearest match above the actual color codes.

My matching algorithm isn’t ideal; it just sums the differences between two colors’ red, green, and blue values. » Continue Reading…

Name That Color

Yelp and Google Places offer competing versions of the same service, as do their APIs. I created the Places Mapper to be able to compare the two. It borrows the same interface as the Yelp Mapper. One difference is that the Yelp API uses text-based searches, while the Places API lets you use their taxonomy of types of businesses. So, you are limited to Google’s choice of what types of places are available, but the results are more accurate. It’s similar to the Metro Places app, but of course you aren’t limited to searching near Metro stations; the entire map is used as the bounds for the search. The API doesn’t return more than 20 results, so if the map covers too large an area, not all relevant places will be returned. » Continue Reading…

bikesI love animating bikesharing systems, but without GPS data it looks like people travel in straight lines, from bike-out to bike-in. So to get a better idea of how cyclists really travel across the city, I wanted to investigate mapping multiple GPS tracks.

The first step is finding data. Strava has a huge repository of bike data, but you can’t access a trips’s GPS data unless you are connected to that person, or if they otherwise grant you access. And even then when you download the GPS data the GPX file doesn’t include timestamps. You can get an idea of the potential of Strava’s data from this “Beautiful Weekend” video made by BikeArlington using VeloViewer.

I decided to try to collect my own GPS data by asking a local monthly bike ride, the DC Bike Party, to record their outing and send me the data. Their April ride attracted 650 riders, but I got only 5 responses, and one of those I had to reject for not having timestamps. But four cyclists is good enough for an experiment to learn more about the process.

The next step was data munging. One participant sent me two separate GPX files, for before and after the break at the bar. It was easy enough to merge them by taking the trkpt tags from one file’s trkseg section and adding them to the other file’s trkseg section. Another participant’s GPX file wasn’t syncing up with the others. To correct it, I just manually edited the timestamps using a global search & replace for the hour field. » Continue Reading…

historyA new map lets you explore historic places in Arlington County, Virginia. I used the Arlington Historical Society‘s web site to learn about historic sites. My Arlington Historic Sites map puts all 107 points on the map. To help people get around, I’ve also included options to show Metro stations and Capital Bikeshare stations.

Some of the historic locations didn’t have exact addresses, so the markers might not be exact. (Let me know if any location should be moved.) Hopefully this is a good way to discover historic sites near you.

Four Metro stations are scheduled to get solicitations for redevelopment this year, as reported by the Washington Business Journal. I used my Metro Places app to take a look at how much transit-oriented development they currently have. The app works by querying the Google Places API to discover businesses within a certain range of Metro stations. I used it to search for gyms, banks, clothing stores, and grocery stores within a radius of 1,000 meters, as a sample of what might be available. The four stations are Forest Glen, West Hyattsville, Braddock Road, and Largo Town Center.

Forest Glen and West Hyattsville are somewhat near each other, albeit in separate counties. The heat map below shows Forest Glen has less nearby development then its neighboring stations. West Hyattsville appears on the edge of an area shared with Prince George’s Plaza, but could benefit from places closer to the station.

» Continue Reading…

If you manage a meetup group, here’s a fun way to display the profile photos of everyone who attends one of your events.

Enter your event ID into my Meetup Explorer app, and it’ll display the profile photo of everyone who RSVP’d “yes” to your event. People without profile photos are not included. To get your event ID, just look at the URL of the event’s page. It’s the big number at the end of the URL.

The program works by using the Meetup API. I use the RSVPs call to get a list of all “yes” RSVPs, and the Groups call to get the name of the event and the name of the group hosting it. » Continue Reading…

A Photo Album of Meetup RSVPs

kpHere’s a simple web app that uses data from the Kaiser Permanente API. Interchange by Kaiser Permanente offers a Location API with four functions you can query. I built the KP Explorer using the Get KP Facilities List call.

I had originally planned a more robust program to demo for the Transportation + Health meetup that was co-sponsored by Mobility Lab and Kaiser Permanente, but couldn’t get the API working in time, so this app doesn’t do much more than demonstrate that the API works.

The program uses geolocation to find your location, or you can enter a place in the search field, or just pan and zoom to a new location and hit “find facilities.” If you’re in one of the 9 states (plus DC) served by KP, you’ll see their facilities. » Continue Reading…

Metro PlacesWhat would the Washington, DC region look like if you never went further than 500 meters from a Metro station? Well, there’s an app for that! I was inspired by a car-free friend who pointed out the difficulty of finding a Metro-accessible dentist when moving to DC. So, let’s put the Internet to work to make that simpler.

I used the Places Library of the Google Maps API to discover dentist locations for a geographic region. To connect to Metro stations, I submitted a separate search for each Metro station. Of course, “dentist” is just one option for a type of place. The API has 96 Supported Place Types, from airport to zoo.

Try the Metro Places app to discover businesses near your favorite Metro station. To make your own search, select the type of place from the drop-down list, which station you want and how many stops you’re willing to travel (I assume no one wants to transfer), and how far you’re willing to walk from the end-station. You can display the results as a collection of icons or a heat map, or both. The icons returned are part of the Places API, such as a giant tooth for dentists, and a martini glass for bars. » Continue Reading…

Washington via WMATA

Should the bikeshare industry adopt an open data standard? As bikesharing spreads to more cities, having a common method for accessing and analyzing data will become more important. We know that transit systems work best when agencies concentrate on their core mission. Transit agencies are not in the information technology business; all they should do is release their data to let third parties build apps that let passengers use the systems.

To use open data, programmers need to know: Where is the data? What are the files called? Which fields are available? What are the fields called?

Bikesharing systems should adopt the standard of having a “data” page which can be found by appending “data” immediately after the main URL. This is what many U.S. government web sites are doing (like,,, etc.) It would be awesome to have consistent URLs like and » Continue Reading…