O'Reilly logo

Building Tag Clouds in Perl and PHP by Jim Bumgardner

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The Utility of Tag Clouds

While you can click on tag clouds, you can also just look at them to get a quick reading of a web site's zeitgeist. Looking at the Flickr tag cloud in Figure 1, you can see that wedding photos are to be found in large quantities, and that they have a lot of photos taken in London and Japan (perhaps at weddings?). Looking at 43 Things (Figure 4), you can see that a lot of people want to get a tattoo. The list at 43 Things is a randomized selection from a much larger list, so if you refresh the page you'll get different winners such as "buy a house," "write a book," and "be happy."

The dual nature of tag clouds comes at the expense of a design trade-off. There are more effective ways to navigate. In general, "browsing" interfaces are not as efficient for finding stuff as searching (and tag clouds are usually accompanied by a standard issue search box, which sees more use). But browsing and searching are two different activities that serve different needs. The dynamic way that tag clouds show popular lists is a remarkably effective way to browse.

There are also more accurate ways to graph tag popularity. Consider the following lists, which show the most common words in the book of Genesis. You could provide tags in a table with actual numbers (Figure 5), or in a bar graph (Figure 6).

Word frequency list

Figure 5. Word frequency list

Figure 6. Word frequency bar graph

These methods both ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required