[UPDATE ON 2012-08-07]

IBM seems to have removed the link to the Word Cloud application so the link below no longer seems to work.

As an alternative, see this discussion on StackOverflow: http://stackoverflow.com/questions/342687/algorithm-to-implement-a-word-cloud-like-wordle, which links to several wordle-type projects.

In particular I suggest looking at WordCram: http://wordcram.org/

 

 

Somehow this hasn’t received the attention it deserves: IBM has released a tool that lets you generate “Wordle” word could images offline on your PC – completely disconnected from the Wordle web site.

Here’s what you have to do, step-by-step

DOWNLOAD AND INSTALL THE JAVA RUNTIME ENVIRONMENT

Go to this page: http://java.sun.com/javase/downloads/index.jsp

You’ll be looking for Java SE Runtime Environment (JRE 6 Update 14 is the latest version). Click download and install it.

image

DOWNLOAD AND INSTALL THE IBM WORD CLOUD GENERATOR

Go to this site

http://www.alphaworks.ibm.com/tech/wordcloud

 

And click on the Download tab

image

 

Click on the Download Now link

image

 

Once you click you’ll have to register (free) with IBM to download the tool.

 

Once you have the zip file … just right click to expand

 

image

 

Inside the folder it creates you’ll see a folder called “IBM Word Cloud”

 

image

You’ll need to run the tool from the command-line so the easiest way to do this is to hold down the SHIFT key and right click on the “IBM World Cloud” folder and select Open command window here

image

Which will launch the command line

image

 

If you look in the folder you’ll see several files

image

The easiest way to get started is just to launch the “run-eample.bat” file from the command line …

 

image

As you can tell from the output – all the script does is specify the …

  • a configuration file
  • the width and height of the image in pixels
  • the input text (“hamlet.txt”)
  • the output filename (“example.png”)

image

You can see now that example.png is in the “IBM Word Cloud” folder. Just right click on the image and select preview…

image

 

And it will open in the photo viewer

image

At this point it should be clear how to generate different sizes of bitmaps. But of course we don’t want pixels, we want the sweet, sweet vector-based goodness.

The way to do this is to specify the –p option in the command line instead of sending the output to a bitmap.

And easy way to make this happen is just to modify the run-example.bat

From this:

image

To this…

image

And this time when you launch the run-example.bat file

image

You’ll see a print dialog instead and you can select a print driver that lets you save to a file. In this case I’ll pick Microsoft XPS Document Writer

 

image

And click OK, and then select the output filename for the XPS file

image

Converting from XPS to a vector format is my next challenge. But if you have adobe acrobat you should be to get the PDF and take the vectors into Illustrator.

PARTING THOUGHTS

  • Looking for recommendations for any free print drivers to create vector output (EMF, PDF, SVG, etc.)
  • I’m going to hook this up to my Twitter search code so that I can get a daily word clouds on my favorite topics