Date: August, 2009
Key Concepts: Spherical coordinates, latitude & longitude conversion, Twitter API, MetaCarta API
GoodMorning! is a global Twitter visualization tool. It allows tweets to be placed geographically and temporally, showing how a word or phrase is used around the world over a certain time period. You can watch a video here.
The project consists of two Processing sketches: a small sketch called TwitGather to gather tweets from the Twitter API and store them with location data in a JSON file, and a larger sketch which renders that data, and allows for export as .MOV and hi-res bitmap files. I’ve included a sample file which holds about 24 hours of ‘Good morning’ tweets.
This is likely the most complicated project that I will be releasing this week. I have tried to document the sketches as thoroughly as possible, but it may be confusing for beginners. However, there are lots of fairly simple things that can be gleaned by looking at various parts of the code.
To compile this project, you’ll need to make sure you have all of the libraries and other dependencies outlined below.
Move the sketches into your Processing sketch folder. Open Processing and open the GoodMorning sketch from the File > Sketchbook menu. You’ll find detailed instructions in the header of the main tab (the GoodMorning.pde file).
GoodMorning uses a variety of libraries, to the authors of which I am extremely grateful:
- Karsten Schmidt’s toxiclibs coreutils for storing coordinates and doing vector math
- Andreas Köberle and Christian Riekoff’s surfaceLib for rendering the planet and cloud layer
- Yusuke Yamamoto’s excellent Twitter4J library for talking to the Twitter API (this library is included in the download)
- Marius Watz’ TileSaver class, which lets you output huge bitmaps from any Processing sketch.
Download: GoodMorning.zip (10.0MB)
This software is licensed under the CC-GNU GPL version 2.0 or later.