I’ve been stuck home with a bad flu for the last few days. The headache and paracetamol intoxication impacted my abilities and willpower, to the point that the only productive thing I did was polishing my backup strategies.
I added duplicity to my Time Machine setup for day-to-day backups. I also found a way to backup my GMail account using getmail. Getmail is written in Python, so I looked a little bit into the libraries that can be used to interact with IMAP. It’s actually very easy to retrieve messages or other statistics; so I had to do something with it.
You’re asking why? Why? Because I love data! I love data like Tarantino likes making movies.
I wrote a script that periodically logs the headers of flagged messages in my inbox, and another that reads the logged data, and plots a couple of statistics: stress, defined as the number of flagged messages; and procrastination, defined as the median age of those messages.
Here’s a snapshot of the result:
For now, I only have three days of data, but you can see it live on my webpage and track my stats in the future.
This is especially useful if you’re waiting for an answer from me!
So cool Andrea! I’ve modified it a bit (some regex to count unique subject lines, other small stuff) and put it up on my homepage. I’m playing with the idea of doing some (basic SARIMA) time series fitting with a prediction a day out or so, when I have more data and some free time to hack. Will be in touch when I’ve got something worth committing back!
Here you go: https://github.com/AndreaCensi/busymail
Sure, tonight I’ll clean it up a little bit and I’ll release it.
Andrea, this is super cool! Can you release the code you used to generate this? I use gmail differently, so I’d prefer to change the ‘stress’ barometer to measure un-archived messages. I’ll gladly commit my changes back to you.