KDnuggets Home » News » 2015 » Oct » Opinions, Interviews, Reports » Trick-or-Treat a Data Scientist ( 15:n34 )

Trick-or-Treat a Data Scientist


How would one infuse Data Science skills in children to optimize candy collection on Halloween? Zeeshan-ul-hassan Usmani (Founder & Chief Data Scientist, PredictifyMe) explains.




halloween-graph-4
Here is an optimization strategy for finding out a house’s probability of participating in Halloween. If the wife is aged between 41 to 50, and the husband 51 to 60, there is 100% chance that you will get a treat. It dramatically reduces down to 25% if the wife is older than 51 and husband has passed his 60th birthday. Similarly, if either of the couple is aged more than 71, you are less likely to get any treats.
halloween-graph-5
This chart shows the number of houses in my neighborhood with the respective age of couples living in them. Out of the four houses with people aged 71 or older, only one participated in Halloween this year.

I found no co-relation with treats and participation with the birth location or house value/rent. I guess, at the end, it is your heart that drives you to celebrate such events, not your pocket.
halloween-graph-6
It gets interesting; this chart shows the cluster of people with their buying preference: which treats are bought to complement which treats. For example, houses in cluster 5 will buy Twizlers, Twix and Harsheys and nothing else. And Cluster 3 would buy Twizlers, Snickers, and Kitkat and nothing else. 87% of households in Cluster 9 bought Lollypops. All the highlighted brands are the one that makes the cluster unique.
halloween-graph-7
We can also map it back to their announced political affiliations in the voter’s database. For example, democrats only come from Cluster 1 and 4, while republicans are fairly distributed among all clusters.

I have also learned that people who just moved to the neighborhood tend to give more treats, so does the parents who have small children in their house. I have estimated the expense on treats in the range of 30-50$ if you have children in home and 10-20$ if you don’t. A similar pattern is observed for expenses on decoration and costumes too. Halloween decoration average in our neighborhood turns out to be $37, while the costumes average is $89. These averages are way above the national average of $75.03 per household for the entire Halloween holiday (decoration + treats + costumes) as published by national retail foundation.
halloween-graph-8
This chart shows the preference of candy with the respective announced political affiliation of the people in the respective households. Blue represents that at least one of the partner in the house is democrat (the other may or may not be UNA). Red represents that at least one of the partner is a republican (again, the other may or may not be UNA). Somehow, Lollypops and KitKats are highly associated with democrats, while Snickers and Butterfinger are associated with Republicans. Give me the candy, and I can tell you who you are going to vote for. I’m not very optimistic about the future though; after all, it’s either a Lollypop, or a (butter)Finger.

Original article

Sign Up

By subscribing you accept KDnuggets Privacy Policy