Alex Poole

Pragmatic PHP, MySQL, Marketing & Technology

Alex Poole header image 2

Paste-in Keyword Density Calculator

August 11th, 2009 by alex

I just knocked this keyword density calculator together for my own use - there are plenty online that take a URL but I wanted one to automatically show the keyword density for offline documents - in other words I wanted to paste in the entire document, not just the URL.

Here’s the keyword density checker source - as you can see I’m using the standard English stopword list from Ranks.nl

The checker automatically calculates the density of every word and 2, 3 and 4 word phrases, ranking the output by density. It strips punctuation and HTML - I’m sure this bit isn’t perfect but it works most of the time.

I haven’t prettied it up either, but I hope its useful to you as is.

Feel free to use the source for anything you like, with no warranty given or implied. Of course I’d always appreciate a link to www.alexpoole.name if you find it useful :)

Tags:   · · · 1 Comment

Leave a Comment

1 response so far ↓

  • am very grateful for your ‘paste in’ ap. all others require URL, which but i need to do via txt or paste.
    awesom app w/ keyword generator. any thought given to allowing user to specify the number of words in a string queried (i only find it helpful to determine phrase frequency).
    i’m doing the above because i’m trying to cluster like articles together. is there a free online clustering tool you know of?
    thanks,
    mark