Haskell, WhatsApp and Romance

Last year, I decided to Learn Me a Haskell for Great Good. Like an enthusiastic kid that I am, I downloaded the latest Haskell platform, got my IDE ready, downloaded a font with funny symbols ligatures, created a new notebook in OneNote, made a sacrifice to Satan.

Then I procrastinated for next six months and got done absolutely nothing.

When I got back to learning, I decided to pick up a project to keep me on track. And so, WhatsUp was born. WhatsUp is a tiny little Haskell app that tells you whats up with your WhatsApp data. It can give various insights about people’s texting habits like word usage, favourite texting times, ability to cram whole essay into a single message and so on. As a test run, I borrowed about five months’ worth of WhatsApp text history and created some pretty visualizations using Tableau.

He was a boy. She was a girl. And here’s their WhatsUp story.

Word Cloud

This one is pretty simple. Bigger and darker the word, more it is used by that person. This doesn’t give us much insight into data, but it looks beautiful. So I like it.

Tree Map

This one is interesting. We can see some patterns here. He uses about as many ‘I’s as ‘you’s. She seems to use about three times ‘I’s as ‘you’s. But that’s completely okay, right? Right?

Message Count by Hour

If we assume that the number of messages send roughly equals the number of replies received, it looks like She is reactive most of the times. Her graph is shifted slightly to the right; probably because of all the replies she sends. She seems to start conversations between 8 PM and 10 PM.

These people don’t talk much from 3 AM to 8 AM. These people need to up their game.

Message Count by Weekday

I have no clue how to interpret this, except that these people don’t talk much on Tuesdays for some reason. I wonder what’s wrong with Tuesdays.

Message Count by Date

Firstly, I expected more or less a flat line here. Why would one have more conversations on a particular date than some other date?

Secondly, the message count is especially low between 16th and 22nd across all the months. Why would that be? I don’t know. When in doubt, blame the PMS.

And that concludes our story for now.

What Comes Next

Learning Haskell and writing WhatsUp was an interesting experience. I also uncovered the story above. I intend to take it further and polish the code as I learn more about functional programming.

Meanwhile, check the code out on GitHub and let the feedback flow.

comments powered by Disqus