Favorite Pastry during Holiday

Analytics exercise to get the best pastry during Lebaran Holiday.

My Mother’s Pastries

I just celebrate Lebaran a week ago (2022–05–02) after Ramadhan fasting. As Indonesian, we celebrate it by visiting our families around town or back to our hometown to meet our parents. In my case, I back to my mother's house and waited for my uncle, aunt, cousin, or other visitors to come. My mother had prepared so much food to welcome them like Ketupat, Rendang, and mostly pastries.

There are several types of pastries in Indonesia which is served specifically during Lebaran. For example Kastengel, Nastar, and Kue Sagu. Some people don't like a specific types of pastries like “too much cheese” or “too sweet”. Even one pastry type could have a different taste that makes people who love it doesn't want to eat it. I’m wondering, what is the favorite pastry of our guest based on what my mother has served?

The Leftover

In the morning one day after Lebaran, I saw pastries leftover in the guest room. Let's say we have 5 types of pastries here. The condition is more or less like in the picture below.

Type A much lesser than the others, and type E still fulfills the jar. Immediately I conclude that type A is the favorite pastry of our guests. Right? Not entirely wrong at least.

But consider this,

  1. My mother could refill pastry type E before I see it. But, why only type E? Maybe my mom just has type E left in the kitchen.
  2. Type A has never been full from the beginning perhaps. I’m not saying every jar starts full.
  3. There might be another pastry type called Type F that has run out on Leabaran day and my mother fill the jar with Type C.

So, the leftover is not really telling me anything about our guest's favorite pastries. The prompt conclusion is still biased since there are many assumptions to be satisfied.

Supposedly my mother has never done a refill and every jar is full from the start. My conclusion should’ve been less biased and I could give my mom a recommendation to buy type A much more for next year. So that we might reduce the overflow.

Then, I remember, there was one of my cousins who took over pastry A jar and eat it up the night before by himself. So, we come back to our board.

The other Point of View

The favorite pastry must represent most of our guests. If we just look at the leftover that is caused by my cousin, then it is better to have another jar just for him and reconsider our favorite pastry. He is the outlier in our case here.

On the other hand, my cousin could be an influencer who can influence others to eat his favorite pastry. Or he could be a person who can represent many people somehow. Unfortunately, he does not satisfy both cases.

Eater Counter

Because of that bias, we could redefine our definition of favorite pastry as a pastry with a high unique number of eaters. The more eaters, the higher chances the pastry is the favorite. In that case, it would be difficult, since I don't have the technology to track the number of eaters at my mother's house. But, presume we have the number, then Type B is the favorite.

Regrettably, I must say that the new definition is still not strong enough. Remember, one eater may eat more than one type of pastry, and Type B may be a new type of pastry so everyone tries to eat at least one.

The Objective

As I have elaborated, a favorite pastry can be defined in many different ways. We can calculate the number of items has been eaten by the guest or calculate the unique guest who has eaten each type. It all depends on the purpose of knowing this favorite pastry.

For example, suppose we have a goal to satisfy our family members rather than our guest in terms of pastry. Then, we can define the favorite pastry as a pastry that has the highest “family score”. I can formulate a simple family score as follow, with an alpha between 0.55 and 1:

The basic family score for pastry x

Where n is the number of people who eat pastry x and q is the number of the pastry x that are eaten by them. Meanwhile, f means “Family” and o is “Other”. As you can see, it basically calculates the “number of people per pastry” with alpha as the weight. The higher the alpha, the more we consider our family.

The other example, if we want to reduce our expenses for next year's Lebaran without reducing our guest satisfaction then we must define the favorite pastry based on the pastry price. Here is an example formula :

Favorite Pastry formula with amt is the price and P is a set of pastries

End of Exercise

In short, the first intuitive answer to certain problems may not give an optimal solution. We must exercise and rethink the solution. On the other hand, sometimes the problem itself is not clear enough from the beginning.

This “Favorite Pastry” problem, for example, doesn’t have a clear goal of what we want to achieve at the start. We are even not clear enough to define what “Favorite” means. In return, we have so many directions to go and the analysis becomes wide open instead of converging to solutions.

In that situation, the analyst must obtain more information about the problem so that they have a solid problem statement. After some time, there may still be not enough information which leads the analyst to construct assumptions.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store