<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/2.3.2" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	>

<channel>
	<title>writing &#124; ben fry</title>
	<link>http://benfry.com/writing</link>
	<description>Visualizing Data</description>
	<pubDate>Thu, 24 Jul 2008 01:31:26 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.3.2</generator>
	<language>en</language>
			<item>
		<title>Wordle me this, Batman</title>
		<link>http://benfry.com/writing/archives/154</link>
		<comments>http://benfry.com/writing/archives/154#comments</comments>
		<pubDate>Thu, 24 Jul 2008 01:31:26 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[inbox]]></category>

		<category><![CDATA[refine]]></category>

		<category><![CDATA[represent]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/154</guid>
		<description><![CDATA[I&#8217;ve never really been fond of tag clouds, but Wordle, by MacGyver of software (and former drummer for They Might Be Giants) Jonathan Feinberg gives the representation an aesthetic nudge lacking in most representations. The application creates word clouds from input data submitted by users. I was reminded of it yesterday by Eugene, who submitted [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve never really been fond of <a href="http://en.wikipedia.org/wiki/Tag_cloud">tag clouds</a>, but <a href="http://wordle.net/">Wordle</a>, by <a href="http://www.youtube.com/watch?v=3w-oDZSLUrY">MacGyver</a> of software (and former drummer for <a href="http://www.tmbg.com/">They Might Be Giants</a>) <a href="http://www.mrfeinberg.com/">Jonathan Feinberg</a> gives the representation an aesthetic nudge lacking in most representations. The application creates word clouds from input data submitted by users. I was reminded of it yesterday by <a href="http://www.226-design.com/">Eugene</a>, who submitted <a href="http://www.lipsum.com/">Lorem Ipsum</a>:</p>
<p><a href="http://wordle.net/gallery/wrdl/81989/lorem_ipsum"><img src="http://benfry.com/wp/wp-content/uploads/2008/07/lorem-500.png" alt="lorem-500.png" /></a></p>
<p>I had first heard about it from emailer from Bill Robertson, who had uploaded <em>Organic Information Design</em>, my master&#8217;s thesis:</p>
<p><a href="http://wordle.net/gallery/wrdl/34768/Organic_Information_Design"><img src="http://benfry.com/wp/wp-content/uploads/2008/07/organic-500.jpg" alt="organic-500.jpg" /></a></p>
<p>A wondeful tree shape! Can&#8217;t decide which I like better: “information” as the stem or “data” as a cancerous growth in the upper-right.</p>
<p>Mr. Feinberg is also the reason that Processing development has been moving to Eclipse (replacing emacs, some shell scripts, two packages of bazooka bubble gum and the command line) because of his donation of a long afternoon helping set up the software in the IDE back when I lived in East Cambridge, just a few blocks from where he works at IBM Research.</p>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/154/feed</wfw:commentRss>
		</item>
		<item>
		<title>Blood, guts, gore and the data fairy</title>
		<link>http://benfry.com/writing/archives/153</link>
		<comments>http://benfry.com/writing/archives/153#comments</comments>
		<pubDate>Wed, 23 Jul 2008 20:56:18 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[iloveme]]></category>

		<category><![CDATA[parse]]></category>

		<category><![CDATA[reviews]]></category>

		<category><![CDATA[vida]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/153</guid>
		<description><![CDATA[The O&#8217;Reilly press folks passed along this review (PDF) of Visualizing Data from USENIX magazine. I really appreciated this part:
My favorite thing about Visualizing Data is that it tackles the whole process in all its blood, guts, and gore. It starts with finding the data and cleaning it up. Many books assume that the data [...]]]></description>
			<content:encoded><![CDATA[<p>The O&#8217;Reilly press folks passed along <a href="http://www.usenix.org/publications/login/2008-04/openpdfs/bookreviews0408.pdf">this review</a> (PDF) of <em>Visualizing Data</em> from <a href="http://www.usenix.org/publications/login/2008-04/index.html">USENIX magazine</a>. I really appreciated this part:</p>
<blockquote><p>My favorite thing about Visualizing Data is that it tackles the whole process in all its blood, guts, and gore. It starts with finding the data and cleaning it up. Many books assume that the data fairy is going to come bring you data, and that it will either be clean, lovely data or you will parse it carefully into clean, lovely data. This book assumes that a significant portion of the data you care about comes from some scuzzy Web page you don’t control and that you are going to use exactly the minimum required finesse to tear out the parts you care about. It talks about how to do this, and how to decide what the minimum required finesse would be. (Do you do it by hand? Use a regular expression? Actually bother to parse XML?)</p></blockquote>
<p>Indeed, writing this book was therapy for that traumatized inner child who learned at such a tender young age that the data fairy did not exist.</p>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/153/feed</wfw:commentRss>
		</item>
		<item>
		<title>NASA Earth Observatory</title>
		<link>http://benfry.com/writing/archives/151</link>
		<comments>http://benfry.com/writing/archives/151#comments</comments>
		<pubDate>Sat, 19 Jul 2008 20:05:00 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[acquire]]></category>

		<category><![CDATA[data]]></category>

		<category><![CDATA[inbox]]></category>

		<category><![CDATA[science]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/151</guid>
		<description><![CDATA[Some potentially interesting data from NASA passed along by Chris Lonnen. The first is the Earth Observatory, which includes images of things like Carbon Monoxide, Snow Cover, Surface Temperature, UV Exposure, and so on. Chris writes:
I&#8217;m not sure how useful they would be to novices in terms of usable data (raw numbers are not provided [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://earthobservatory.nasa.gov/Newsroom/NewImages/Images/carbon_200201.mov"><img src="http://benfry.com/wp/wp-content/uploads/2008/07/carbon.thumbnail.jpg" alt="carbon.jpg" align="right" hspace="13" /></a>Some potentially interesting data from NASA passed along by Chris Lonnen. The first is the <a href="http://earthobservatory.nasa.gov/Observatory/datasets.html">Earth Observatory</a>, which includes images of things like Carbon Monoxide, Snow Cover, Surface Temperature, UV Exposure, and so on. Chris writes:</p>
<blockquote><p>I&#8217;m not sure how useful they would be to novices in terms of usable data (raw numbers are not provided in any easy to harvest manner), but the information is<br />
still useful and they provide for a basic, if clunky, presentation that follows the basic steps you laid out in your book. They data can be found <a href="http://earthobservatory.nasa.gov/Observatory/datasets.html">here</a>, and they occasionally compile it all into interesting visualizations. My favorite being the carbon map <a href="http://earthobservatory.nasa.gov/Newsroom/NewImages/Images/carbon_200201.mov">here</a>.</p></blockquote>
<p>The carbon map movie is really cool, though I wish the raw data were available since the strong cyclical effect seen in the animation needs to be separated out. The cycles dominates the animation to such an extent that it&#8217;s nearly the only takeaway from the movie. For instance, each cycle is a 24 hour period. Instead of showing them one after another, show several days adjacent one another, so that we can compare 3am with one day to 3am the next.</p>
<p>For overseas readers, I&#8217;ll note that the images and data are not all U.S.-centric—most cover the surface of the Earth.</p>
<p>I asked Chris about availability for more raw data, and he did a little more digging:</p>
<blockquote><p>The raw data availability is slim. From what I&#8217;ve gathered you need to contact NASA and have them give you clearance as a researcher. If you were looking for higher quality photography for a tutorial NASA Earth Observations has a <a href="http://neo.sci.gsfc.nasa.gov">newer website</a> that I&#8217;ve just found which offers similar data in the format of your choice at up to 3600 x 1800. For some sets it will also offer you data in CSV or CSV for Excel.</p>
<p>If you needed higher resolutions that that <a href="http://visibleearth.nasa.gov/">NASA&#8217;s Visible Earth</a> offers some TIFF&#8217;s at larger sizes. A quick search for .tiff gave me an 16384 x 8192 map of the earth with city lights shining, which would be relatively easy to filter out from the dark blue background. These two websites are probably a bit more helpful.</p></blockquote>
<p>Interesting tidbits for someone interested in a little planetary digging. I&#8217;ve had a few of these links sitting in a pile waiting for me to finish the “data” section of my web site; in the meantime I&#8217;ll just mention things here.</p>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/151/feed</wfw:commentRss>
<enclosure url="http://earthobservatory.nasa.gov/Newsroom/NewImages/Images/carbon_200201.mov" length="6708486" type="video/quicktime" />
		</item>
		<item>
		<title>Brains on the Line</title>
		<link>http://benfry.com/writing/archives/147</link>
		<comments>http://benfry.com/writing/archives/147#comments</comments>
		<pubDate>Wed, 16 Jul 2008 15:53:55 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[football]]></category>

		<category><![CDATA[sports]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/147</guid>
		<description><![CDATA[I was reminded this morning that Mario Manningham, a wide receiver who played for Michigan was rumored to have scored a 6 (out of 50) on the Wonderlic, an intelligence test administered in some occupations (and now pro football) to check the mental capability of job candidates. Intelligence tests are strange beasts, but after watching [...]]]></description>
			<content:encoded><![CDATA[<p>I was <a href="http://www.profootballtalk.com/2008/07/15/mario-manningham-signs-with-giants/">reminded this morning</a> that Mario Manningham, a wide receiver who played for Michigan was rumored to have scored a 6 (out of 50) on the <a href="http://www.wonderlic.com/">Wonderlic</a>, an intelligence test administered in some occupations (and now pro football) to check the mental capability of job candidates. Intelligence tests are strange beasts, but after watching my niece working on similar problems—for fun—during her summer vacation last week, the tests caught my eye more than when I first heard about it.</p>
<p>Manningham was once a promising undergrad receiver for U of M, but has in recent years proven himself to be a knucklehead, loafing through plays and most recently <a href="http://www.profootballtalk.com/2008/04/14/hole-gets-deeper-for-manningham/">making headlines</a> for marijuana use and an interview on Sirius radio described as “&#8230; arrogant and defensive.  When asked about the balls he dropped in big spots, he responded, ‘What about the ball I caught?’” So while an exceptionally score on a standardized test might suggest dyslexia, the guy&#8217;s an egotistical bonehead even without mitigating factors.</p>
<p>Most people don&#8217;t associate brains with football, but in recent years teams have begun to use a Wonderlic test while scouting, which consists of 50 questions to be completed in 12 minutes. Many of the questions are multiple choice, but the time is certainly a factor when completing the tests. A score of 10 is considered “literate”, while 20 is said to coincide with average intelligence (an IQ of 100, though now we&#8217;re comparing one somewhat arbitrary numerically scored intelligence test with another).</p>
<p>In another interesting twist, the test is also administered to players the day of the NFL combine—which means they first spend the day running, jumping, benching, interviewing, and lots of other -ings, before they sit down and take an intelligence test. It&#8217;s a bit like a medical student running a half marathon before taking the boards.</p>
<p>Wonderlic himself says that basically, the scores decrease as you move <a href="http://sports.espn.go.com/espn/print?id=1342036&amp;type=story">further away from the ball</a>, which is interesting but unsurprising. It&#8217;s sort of obvious that a quarterback needs to be on the smarter side, but I was curious to see what this actually looked like. Using <a href="http://en.wikipedia.org/wiki/Wonderlic_Test">this table</a> as a guide, I then grabbed <a href="http://en.wikipedia.org/wiki/Image:American_football_positions.svg">this diagram</a> from Wikipedia showing a typical formation in a football game. I cleaned up the design of the diagram a bit and replaced the positions with their scores:</p>
<p><img src="http://benfry.com/wp/wp-content/uploads/2008/07/positions1.png" alt="positions1.png" /></p>
<p>Offense is shown in blue, defense in red. You can see the quarterback with a 24, the center (over 6 feet and around 300 lbs.) averaging higher at 25, and the outside linemen even a little higher. Presumably this is because the outside linemen need to mentally quick (as well as tough) to read the defense and respond to it. Those are the wide receivers (idiot loud mouths) with the 17s on the outside.</p>
<p>To make the diagram a bit clearer, I scaled each position based on its score:</p>
<p><img src="http://benfry.com/wp/wp-content/uploads/2008/07/positions2.png" alt="positions2.png" /></p>
<p>That&#8217;s a little better since you can see the huddle around the ball and where the brains need to be for the system of protection around it. With the proportion, I no longer need the numbers, so I&#8217;ve switched back to using the initials for each position&#8217;s title:</p>
<p><img src="http://benfry.com/wp/wp-content/uploads/2008/07/positions3.png" alt="positions3.png" /></p>
<p>(Don&#8217;t tell Tufte that I&#8217;ve used the radius, not the proportional area, of the circle as the value for each ellipse! A cardinal sin that I&#8217;m using in this case to improve proportion and clarify a point.)</p>
<p>I&#8217;ll also happily point out that the linemen for the Patriots all score <a href="http://www.sportingnews.com/yourturn/viewtopic.php?p=2922660">above average</a> for their position:</p>
<p align=center>
<table cellpadding="4">
<tr>
<td align="left"><strong> Player </strong></td>
<td align="left"><strong> Position </strong></td>
<td><strong> Year </strong></td>
<td><strong> Score </strong></td>
</tr>
<tr>
<td>Matt Light</td>
<td>left tackle</td>
<td>2001</td>
<td>29</td>
</tr>
<tr>
<td>Logan Mankins</td>
<td>left guard</td>
<td>2005</td>
<td>25</td>
</tr>
<tr>
<td>Dan Koppen</td>
<td>center</td>
<td>2003</td>
<td>28</td>
</tr>
<tr>
<td>Stephen Neal</td>
<td>right guard</td>
<td>2001</td>
<td>31</td>
</tr>
<tr>
<td>Nick Kaczur</td>
<td>right tackle</td>
<td>2005</td>
<td>29</td>
</tr>
</table>
<p>A position-by-position image for a team would be interesting, but I&#8217;ve already spent too much time thinking about this. The Patriots are rumored to be heavy on brains, with Green Bay at the other end of the spectrum.</p>
<p>An ESPN writeup about the test (and testing in general) can be found <a href="http://espn.go.com/page2/s/closer/020228.html">here</a>, along with a sample test <a href="http://espn.go.com/page2/s/closer/020228test.html">here</a>.</p>
<p>One <a href="http://www.wonderlic.com/resources/newsletters/2005Spring/quizNFL.asp">odd press release</a> from Wonderlic even compares scores per NFL position with private sector job titles. For instance, a middle linebacker scores like a hospital orderly, while an offensive tackle is closer to a marketing executive. Fullbacks and halfbacks share the lower end with dock hands and material handlers.</p>
<p>During the run-up to <a href="http://sportsillustrated.cnn.com/football/nfl/superbowl/32/">Super Bowl XXXII</a> in 1998, one reporter even <a href="http://www2.jsonline.com/packer/sbxxxii/news/wond12198.stm">dug up the Wonderlic scores</a> for the Broncos and Packers, showing Denver with an average score of 20.4 compared to Green Bay&#8217;s 19.6. As defending champions, the Packers were favored but wound up losing 31-24.</p>
<p>Nobody cited test scores in the post-game coverage.</p>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/147/feed</wfw:commentRss>
		</item>
		<item>
		<title>Eric Idle on “Scale”</title>
		<link>http://benfry.com/writing/archives/146</link>
		<comments>http://benfry.com/writing/archives/146#comments</comments>
		<pubDate>Wed, 16 Jul 2008 12:03:11 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[music]]></category>

		<category><![CDATA[scale]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/146</guid>
		<description><![CDATA[Scale is one of the most important themes in data visualization. In Monty Python&#8217;s The Meaning of Life, Eric Idle shares his perspective:

The lyrics:
 Just remember that you&#8217;re standing on a planet that&#8217;s evolving
And revolving at nine hundred miles an hour,
That&#8217;s orbiting at nineteen miles a second, so it&#8217;s reckoned,
A sun that is the source [...]]]></description>
			<content:encoded><![CDATA[<p>Scale is one of the most important themes in data visualization. In Monty Python&#8217;s <a href="http://www.amazon.com/exec/obidos/ASIN/B0000A0MFJ/ref=nosim/benfrycom-20"><em>The Meaning of Life</em></a>, Eric Idle shares his perspective:</p>
<p><embed src="http://www.vimeo.com/moogaloop.swf?clip_id=1350717&amp;server=www.vimeo.com&amp;show_title=0&amp;show_byline=0&amp;show_portrait=0&amp;color=00ADEF&amp;fullscreen=1" type="application/x-shockwave-flash" allowfullscreen="true" height="263" width="480"></embed></p>
<p>The lyrics:</p>
<blockquote><p> Just remember that you&#8217;re standing on a planet that&#8217;s evolving<br />
And revolving at nine hundred miles an hour,<br />
That&#8217;s orbiting at nineteen miles a second, so it&#8217;s reckoned,<br />
A sun that is the source of all our power.<br />
The sun and you and me and all the stars that we can see<br />
Are moving at a million miles a day<br />
In an outer spiral arm, at forty thousand miles an hour,<br />
Of the galaxy we call the &#8216;Milky Way&#8217;.</p>
<p>Our galaxy itself contains a hundred billion stars.<br />
It&#8217;s a hundred thousand light years side to side.<br />
It bulges in the middle, sixteen thousand light years thick,<br />
But out by us, it&#8217;s just three thousand light years wide.<br />
We&#8217;re thirty thousand light years from galactic central point.<br />
We go &#8217;round every two hundred million years,<br />
And our galaxy is only one of millions of billions<br />
In this amazing and expanding universe.</p>
<p>The universe itself keeps on expanding and expanding<br />
In all of the directions it can whizz<br />
As fast as it can go, at the speed of light, you know,<br />
Twelve million miles a minute, and that&#8217;s the fastest speed there is.<br />
So remember, when you&#8217;re feeling very small and insecure,<br />
How amazingly unlikely is your birth,<br />
And pray that there&#8217;s intelligent life somewhere up in space,<br />
&#8216;Cause there&#8217;s bugger all down here on Earth. <img src="http://www.lyricsdepot.com/images/t/9.gif" height="1" width="1" /></p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/146/feed</wfw:commentRss>
		</item>
		<item>
		<title>Postleitzahlen in Deutschland</title>
		<link>http://benfry.com/writing/archives/144</link>
		<comments>http://benfry.com/writing/archives/144#comments</comments>
		<pubDate>Tue, 15 Jul 2008 21:33:16 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[adaptation]]></category>

		<category><![CDATA[vida]]></category>

		<category><![CDATA[zipdecode]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/144</guid>
		<description><![CDATA[Maximillian Dornseif has adapted Zipdecode from Chapter 6 of Visualizing Data to handle German postal codes. I&#8217;ve wanted to do this myself since hearing about the OpenGeoDB data set which includes the data, but thankfully he&#8217;s taken care of it first and is sharing it with the rest of us along with his modified code.
(The [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://benfry.com/wp/wp-content/uploads/2008/07/germany-contrast-small.png" alt="germany-contrast-small.png" align="right" hspace="13" vspace="0" />Maximillian Dornseif has adapted <a href="http://benfry.com/zipdecode/">Zipdecode</a> from Chapter 6 of <a href="http://www.amazon.com/exec/obidos/ASIN/0596514557/ref=nosim/benfrycom-20"><em>Visualizing Data</em></a> to handle <a href="http://md.hudora.de/c0de/zipdecodeDE/">German postal codes</a>. I&#8217;ve wanted to do this myself since hearing about the <a href="http://opengeodb.hoppe-media.com/">OpenGeoDB</a> data set which includes the data, but thankfully he&#8217;s taken care of it first and is sharing it with the rest of us along with his modified code.</p>
<p>(The site is in German&#8230;I&#8217;ll trust any of you German readers to let me know if the site actually says that <em>Visualizing Data</em> is the dumbest book he&#8217;s ever read.)</p>
<p>Also helpful to note that he used Python for preprocessing the data. He doesn&#8217;t bother implementing a map projection, as done in the book, but the Python code is a useful example of using another language when appropriate, and how the syntax differs from Processing:</p>
<pre># Convert opengeodb data for zipdecode
fd = open('PLZ.tab')
out = []
minlat = minlon = 180
maxlat = maxlon = 0

for line in fd:
    line = line.strip()
    if not line or line.startswith('#'):
        continue
    parts = line.split('\t')
    dummy, plz, lat, lon, name = parts
    out.append([plz, lat, lon, name])
    minlat = min([float(lat), minlat])
    minlon = min([float(lon), minlon])
    maxlat = max([float(lat), maxlat])
    maxlon = max([float(lon), maxlon])

print "# %d,%f,%f,%f,%f" % (len(out), minlat, maxlat, minlon, maxlon)
for data in out:
    plz, lat, lon, name = data
    print '\t'.join([plz, str(float(lat)), str(float(lon)), name])</pre>
<p>In the book, I used Processing for most of the examples (with a little bit of Perl) for sake of simplicity. (The book is already introducing a lot of new material, why hurt people and introduce multiple languages while I&#8217;m at it?) However that&#8217;s one place where the book diverges from my own process a bit, since I tend to use a lot of Perl when dealing with large volumes of text data. Python is also a good choice (or Ruby if that&#8217;s your thing), but I&#8217;m tainted since I learned Perl first, while a wee intern at Sun.</p>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/144/feed</wfw:commentRss>
		</item>
		<item>
		<title>Parsing Numbers by the Bushel</title>
		<link>http://benfry.com/writing/archives/143</link>
		<comments>http://benfry.com/writing/archives/143#comments</comments>
		<pubDate>Tue, 15 Jul 2008 14:23:55 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[parse]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/143</guid>
		<description><![CDATA[While taking a look at the code mentioned in the previous post, I noticed two things. First, the PointCloud.pde file drops directly into OpenGL-specific code (rather than Processing API) for sake of speed to draw thousands and thousands of points. It&#8217;s further proof that I need to finish the PShape class for Processing 1.0, which [...]]]></description>
			<content:encoded><![CDATA[<p>While taking a look at the code mentioned in the <a href="http://benfry.com/writing/archives/142">previous post</a>, I noticed two things. First, the PointCloud.pde file drops directly into OpenGL-specific code (rather than Processing API) for sake of speed to draw thousands and thousands of points. It&#8217;s further proof that I need to finish the PShape class for Processing 1.0, which will automatically handle this sort of thing automatically.</p>
<p>Second is a more general point about parsing. This isn&#8217;t intended as a nitpick on Aaron&#8217;s code (it&#8217;s commendable that he put his code out there for everyone to see—and uh, nitpick about). But seeing how it was written reminded me that most people don&#8217;t know about the casts in Processing, particularly when applied to whole arrays, and this can be really useful when parsing data.</p>
<p>To convert a String to a float (or int) in Processing, you can use a cast, for instance:</p>
<pre>String s = "667.12";
float f = float(s);</pre>
<p>This also in fact works with String[] arrays, like the kind returned by the split() method while parsing data. For instance, in SceneViewer.pde, the code currently reads:</p>
<pre>String[] thisLine = split(raw[i], ",");
points[i * 3] = new Float(thisLine[0]).floatValue() / 1000;
points[i * 3 + 1] = new Float(thisLine[1]).floatValue() / 1000;
points[i * 3 + 2] = new Float(thisLine[2]).floatValue() / 1000;</pre>
<p>Which could be written more cleanly as:</p>
<pre>String[] thisLine = split(raw[i], ",");
float[] f = float(thisLine);
points[i * 3 + 0] = f[0] / 1000;
points[i * 3 + 1] = f[1] / 1000;
points[i * 3 + 2] = f[2] / 1000;</pre>
<p>However, to his credit, Aaron may have have intentionally skipped it in this case since he don&#8217;t need the whole line of numbers.</p>
<p>Or if you&#8217;re using the Processing API with Eclipse or some other IDE, that means that the float() cast won&#8217;t work for you. You can substitute float() with the parseFloat() method:</p>
<pre>String[] thisLine = split(raw[i], ",");
float[] f = parseFloat(thisLine);
points[i * 3 + 0] = f[0] / 1000;
points[i * 3 + 1] = f[1] / 1000;
points[i * 3 + 2] = f[2] / 1000;</pre>
<p>The same can be done for int, char, byte, and boolean. You can also go the other direction by converting float[] or int[] arrays to String[] arrays using the str() method. (The method is named str() because a String() cast would be awkward, a string() cast would be error prone, and it&#8217;s not really parseStr() either.)</p>
<p>When using parseInt() and parseFloat() (versus the int() and float() casts), it&#8217;s also possible to include a second parameter that specifies a “default” value for missing data. Normally, the default is Float.NaN for parseFloat(), or 0 with parseInt() and the others. When parsing integers, 0 and “no data” often have a very different meaning, in which case this can be helpful.</p>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/143/feed</wfw:commentRss>
		</item>
		<item>
		<title>Radiohead - House of Cards</title>
		<link>http://benfry.com/writing/archives/142</link>
		<comments>http://benfry.com/writing/archives/142#comments</comments>
		<pubDate>Tue, 15 Jul 2008 13:41:24 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[data]]></category>

		<category><![CDATA[motion]]></category>

		<category><![CDATA[music]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/142</guid>
		<description><![CDATA[Radiohead&#8217;s new video for “House of Cards” built using a laser scanner and software:



Aaron Koblin, one of Casey&#8217;s former students was involved in the project and also made use of Processing for the video. He writes:
A couple of hours ago was the release of a project I&#8217;ve been working on with Radiohead and Google. Lots [...]]]></description>
			<content:encoded><![CDATA[<p>Radiohead&#8217;s new video for “House of Cards” built using a laser scanner and software:</p>
<p><object width="425" height="344">
<param name="movie" value="http://www.youtube.com/v/8nTFjVm9sTQ&#038;hl=en&#038;fs=1&#038;rel=0"></param>
<param name="allowFullScreen" value="true"></param><embed src="http://www.youtube.com/v/8nTFjVm9sTQ&#038;hl=en&#038;fs=1&#038;rel=0" type="application/x-shockwave-flash" allowfullscreen="true" width="425" height="344"></embed></object></p>
<p><a href="http://aaronkoblin.com/">Aaron Koblin</a>, one of <a href="http://reas.com">Casey&#8217;s</a> former students was involved in the project and also made use of <a href="http://processing.org">Processing</a> for the video. He writes:</p>
<blockquote><p>A couple of hours ago was the release of a project I&#8217;ve been working on with Radiohead and Google. Lots of laser scanner fun.</p>
<p>I released some Processing code along with the data we captured to make the video. Also tried to give a basic explanation of how to get started using Processing to play with all this stuff.</p></blockquote>
<p>The project is hosted at <a href="http://code.google.com/radiohead">code.google.com/radiohead</a>, where you can also download all the data for the point clouds captured by the scanner, as well as Processing source code to render the points and rotate Thom&#8217;s head as much as you&#8217;d like. <a href="http://code.google.com/p/radiohead/downloads/list">This</a> is the download page for the data and source code.</p>
<p>They&#8217;ve also posted a “making of” video:</p>
<p><object width="425" height="344">
<param name="movie" value="http://www.youtube.com/v/cyQoTGdQywY&#038;hl=en&#038;fs=1&#038;rel=0"></param>
<param name="allowFullScreen" value="true"></param><embed src="http://www.youtube.com/v/cyQoTGdQywY&#038;hl=en&#038;fs=1&#038;rel=0" type="application/x-shockwave-flash" allowfullscreen="true" width="425" height="344"></embed></object></p>
<p>(Just cover your ears toward the end where the director starts going on about “everything is data&#8230;”)</p>
<p>Sort of wonderful and amazing that they&#8217;re releasing the data behind the project, opening up the possibility for a kind of software-based remixing of the video. I hope their leap of faith will be rewarded by individuals doing interesting and amazing things with the data. (Nudge, nudge.)</p>
<p>Aaron&#8217;s also behind the excellent <a href="http://aaronkoblin.com/work/flightpatterns/">Flight Patterns</a> as well as <a href="http://aaronkoblin.com/work/thesheepmarket/">The Sheep Market</a>, both highly recommended.</p>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/142/feed</wfw:commentRss>
		</item>
		<item>
		<title>Derek Jeter Probably Didn&#8217;t Need To Jump To Throw That Guy Out</title>
		<link>http://benfry.com/writing/archives/140</link>
		<comments>http://benfry.com/writing/archives/140#comments</comments>
		<pubDate>Mon, 14 Jul 2008 16:34:41 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[baseball]]></category>

		<category><![CDATA[mine]]></category>

		<category><![CDATA[sports]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/140</guid>
		<description><![CDATA[Derek Jeter vs. Objective Reality is an entertaining article from Slate regarding a study by Shane T. Jensen at the Wharton School. Nate DiMeo writes:
The take-away from the study, which was presented at the annual meeting of the American Association for the Advancement of Science, was that Mr. Jeter (despite his three Gold Gloves and [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.slate.com/id/2195149/pagenum/all/"><img src="http://benfry.com/wp/wp-content/uploads/2008/07/05jeterderek14.thumbnail.jpg" alt="05jeterderek14.jpg" align="right" hspace="9" vspace="9" />Derek Jeter vs. Objective Reality</a> is an entertaining article from <em>Slate</em> regarding a <a href="http://stat.wharton.upenn.edu/~stjensen/research/safe.html">study</a> by <a href="http://www-stat.wharton.upenn.edu/~stjensen/">Shane T. Jensen</a> at the Wharton School. Nate DiMeo writes:</p>
<blockquote><p>The take-away from the study, which was presented at the annual meeting of the American Association for the Advancement of Science, was that Mr. Jeter (despite his three Gold Gloves and balletic leaping throws) is the worst-fielding shortstop in the game.</p></blockquote>
<p>The New York press was unhappy, but the stats-minded baseball types (Sabermetricians) weren&#8217;t that impressed. DiMeo continues:</p>
<blockquote><p>Mostly, though, the paper didn&#8217;t provoke much intrigue because Jeter&#8217;s badness is already an axiom of [Sabermetric literature]. In fact, debunking the conventional wisdom about the Yankee captain&#8217;s fielding prowess has become a <strong>standard method of proving the validity of a new fielding statistic. That places Derek Jeter at the frontier of new baseball research. </strong></p></blockquote>
<p>Well put. Mr. Jeter <a href="http://www.nypost.com/seven/02212008/sports/yankees/computer_crash_98561.htm">defended himself</a> by saying:</p>
<blockquote><p>“Maybe it was a computer glitch”</p></blockquote>
<p>What I like about the article, aside from a objective and quantitative reason to dislike Jeter (I already have a quantity of subjective reasons) is how the article frames the issue in the broader sports statistics debate. It nicely covers this new piece of information as a microcosm of the struggle between sabermetricians and traditional baseball types, while essentially poking fun at both: the total refusal of the traditional side to buy into the numbers, and the schadenfreude of the geeks going after Jeter since he&#8217;s the one who gets the girls. (The article is thankfully not as trite as that, but you get the idea.)</p>
<p>I&#8217;m also biased since the metric in the paper places <a href="http://www.boston.com/sports/baseball/redsox/extras/2004wallpaper/">Pokey Reese</a>, one of my favorite Red Sox players of 2004 as #11 amongst second basemen between 2000-2005.</p>
<p>And of course, <em>The Onion</em> <a href="http://www.theonion.com/content/node/51318">does it better</a>:</p>
<blockquote><p>Experts: &#8216;Derek Jeter Probably Didn&#8217;t Need To Jump To Throw That Guy Out&#8217;</p>
<p>BRISTOL, CT—Baseball experts agreed Sunday that Derek Jeter, who fielded a routine ground ball during a regular-season game in which the Yankees were leading by five runs and then threw it to first base using one of his signature leaps, did not have to do that to record the out. &#8220;If it had been a hard-hit grounder in the hole or even a slow dribbler he had to charge, that would&#8217;ve been one thing,&#8221; analyst John Kruk said during a broadcast of <em>Baseball Tonight</em>. &#8220;But when it&#8217;s hit right to him by [Devil Rays first-baseman] Greg Norton, a guy who has no stolen bases and is still suffering the effects of a hamstring injury sustained earlier this year… Well, that&#8217;s a different story.&#8221; Jeter threw out Norton by 15 feet and pumped his fist in celebration at the end of the play.</p></blockquote>
<p>In other news, I can&#8217;t believe I just put a picture of Jeter on my site.</p>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/140/feed</wfw:commentRss>
		</item>
		<item>
		<title>Storyboarding with the Coen Brothers</title>
		<link>http://benfry.com/writing/archives/138</link>
		<comments>http://benfry.com/writing/archives/138#comments</comments>
		<pubDate>Fri, 27 Jun 2008 05:07:28 +0000</pubDate>
		<dc:creator>admin</dc:creator>
		
		<category><![CDATA[drawing]]></category>

		<category><![CDATA[movies]]></category>

		<guid isPermaLink="false">http://benfry.com/writing/archives/138</guid>
		<description><![CDATA[Wonderful article about the work of J. Todd Anderson, who storyboards the Coen Brothers&#8217; movies:
Anderson’s drawings have a jauntiness that seems absent from the more serious cinematic depiction; Anderson says he is simply trying to inject as much of a sense of action as possible into each scene.
Anderson describes the process of meeting about a [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.myamericanartist.com/2008/05/coen-brothers-m.html"><img src="http://benfry.com/wp/wp-content/uploads/2008/06/0805ande1_533x600_4.thumbnail.jpg" alt="0805ande1_533x600_4.jpg" align="right" hspace="13" vspace="13" /></a>Wonderful <a href="http://www.myamericanartist.com/2008/05/coen-brothers-m.html">article</a> about the work of J. Todd Anderson, who storyboards the Coen Brothers&#8217; movies:</p>
<blockquote><p>Anderson’s drawings have a jauntiness that seems absent from the more serious cinematic depiction; Anderson says he is simply trying to inject as much of a sense of action as possible into each scene.</p></blockquote>
<p>Anderson describes the process of meeting about a new film:</p>
<blockquote><p>“It’s like they’re making a movie in front of me,” he says. “They tell me the shots. I do fast and loose drawings on a clipboard with a Sharpie pen—one to three drawings to a sheet of regular bond paper. I try to establish the scale, trap the angle, ID the character, get the action.”</p></blockquote>
<p>More in <a href="http://www.myamericanartist.com/2008/05/coen-brothers-m.html">the article</a>&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://benfry.com/writing/archives/138/feed</wfw:commentRss>
		</item>
	</channel>
</rss>
