NOTE (Mar 16, 2014): This visualization has been modified to work with the new 1.1 twitter api, as twitter removed the version that this visualization was originally built against. You can see the updated version at the link below:
Per the new api, you must sign in via twitter in order to use the search functionality. There are some notes on this implementation using node.js in this blog post.
All of the information below pertains to the old, no-longer-working version.
For tweets that include lat/long information, the county is determined via a dynamic call to the FCC census block conversions api (I haven't gotten around to geocoding this map which would make this step unnecessary).
There are already tweet maps out there - enough to make me think I should have named this little project "Yet Another Tweet Map". Most seem to use the google maps api. Some of these are also hooked straight into the twitter public stream api rather than simply making use of the twitter search API as is done here.
- TwitterMap, a project by Matthew Isabel, is also based on D3, and allows a search of tweets in the US - he plots the tweets at their actual latitude/longitude on the US map
- Tweereal integrates google maps with the twitter public stream to show the pattern of tweets across the world; the tweets (without the tweet contents) are marked with colorful circles that beautifully appear and fade like raindrops hitting the globe
- the One Million Tweet map shows a world map of the last
onetwo million tweets, has options for filtering by keyword, and can show activity either via big circles with tweet counts, or via a heat map
- Trendsmap is another map shows Twitter trends around the world
- CoffeeMorning shows tweets in the UK about the Macmillan Cancer Support fundraising event (via certain hashtags)
- Tweet to Map is an inexpensive jQuery plugin that simplifies integration with Google maps (it seems to use Twitter's api rather than the twitter firehouse)
- #uksnow integrates google maps with the twitter search api to report on where it is snowing in the UK
- Globaltweets is another mashup with google maps that shows tweets around the world
- Twittervision is a perhaps one of the first mashups with google maps (from 2007!), but this is apparently no longer working
Searching for Tweets
Searching can be done in a somewhat "google-like" manner, although you've got to include a "+" to force the term or quoted phrase to be there. You can also make sure that a term not be included by prepending a "-". If neither prefix is included, then the term is optional. The entered search string is mapped to the proper format needed by the twitter api itself. Well, the version 1 api, which is deprecated and will be unavailable at some point. The v1.1 search api requires a "signed user context", which involves using oAuth with twitter, and that's a little project for another day.
xkcd is On To Me
This is an interesting project to work on, but the geographic aspect hasn't seemed to be particularly insightful yet. Searching for "+rain +school" the other night, it did show little Knox County,TN as a single bright red county across the country from angry school kids when all the counties around it closed schools for rain the next day and Knoxville didn't. So, you can see some geographic uniqueness by choosing specific search terms, but I have a feeling that in most cases you're just watching a population density heat map get filled in (note that this is definitely the case for the birth/death simulation I was part of putting together). xkcd has already spoken on this: