← Home

A better Mephisto Tag Cloud Plugin

I added some usage instructions to my Mephisto TagCloud plugin page. So if you want to try and install this brilliant piece of software you might want to head over there for more info.

Tag weight distribution

The hardest thing with a tag cloud is the distribution algorithm because it has to work with very different sets of data.

There are a couple of interesting reads about that out there ... here are some which I found useful or interesting:

To be able to better watch the differences in the results with different distribution algorithms I added a simple tag weight distribution graph to the plugin. You can add a route like the following:


# config/routes.rb
map.connect 'tagcloud/distribution',
            :controller => 'tag_cloud',
            :action => 'distribution'

E.g. with the options:


TagCloud.method = :log
TagCloud.order = :weight
TagCloud.weights = 6

... the tags dataset on my blog would show this graph:

That's a bit steep. By setting the option TagCloud.method = :log though I get a distribution like this:

... which is far better.

Obviously this tag weight and distribution stuff requires quite some research and I guess there's no silver bullet (again) that suits well for all tag data sets. So if you install this plugin I'd really appreciate to learn about how this works for you. Even more so if you tweaked it and found something different to work better!