# pretty last.fm graphs

Have you seen Lastgraph or Lee Byron’s work? Like it? Upset you can’t see the source code and play with it? Well, this might be what you’re after.
Utilising the scrobbler gem, I’ve written some Ruby which does something similar, and here’s the code so you can play with it yourself.
Just change the username on line 100, and run it. The script will download your data from last.fm, and produce a nice .svg for you (Warning: quite large.) To be friendly to last.fm, it caches the data on disk, so subsequent runs are generated a little quicker than your first run.
If you want to hack around with it, then I warn you that the second half of the source code is nasty, but subsequent versions will be tidier. It should be fairly easy to work out and modify. The code is released into the public domain, do as you please with it.
I’m sure some of the calculations in the code are inadvertently tailored to accounts with a similar amount of data as mine, so I’d be interested to hear if anyone does have any success with it. Email me via the link at the bottom of the page.
Posted in Code, DataVisualisation, Music, Ruby • 22.06.07 • #