My Tableau Cookbook

During this lockdown, I realized a lot of things. One of them is that I can cook. However, the recipes I try are located on different websites and 2 weeks later I don’t even remember where I saved them. I can’t help mentioning Alison Roman’s Chickpea stew that broke the internet last year, because it’s among the top dishes I’ve ever made. That’s when the idea came to make my cookbook, and if I do it, why not make it in Tableau? Why? Just because it can be done. Have a look at it on Tableau Public.

Final design in Tableau

At first, I started with three recipes to make a prototype, but the idea is to publish the best cake recipes from the yearly baking contest at the company. The data behind the visualization is as simple as it can be, only contains three rows. The fields I had in the Excel sheet were recipe name, ingredients, meal-type, serving size, cooking time, complexity, lactose-free, gluten-free, vegan, story, steps, and quotes. Of course, you can get creative with it, one of my commenters on Twitter wrote, that she’ll build a dietary plan for her mother in Tableau.

The inspiration for the layout I found on Pinterest and recreated something similar using Illustrator. The predesign is really simple, you can even do it in PowerPoint or Figma. Make sure to use the same websafe font on the background image, that you’ll use in Tableau. If you want to create your own cookbook, here are some cool layout ideas for you on a recipe design board.

My cookbook layout board

The images I downloaded from Pexels, cut them to the same size, and laid a grey rectangle over them with high opacity to make them more look similar to each other. It’s a slight difference, but it adds a lot to the final design.

Top: the original images, Bottom: images with a grey overlay

The next step was to have a dynamic switching effect based on the recipes we’re selecting. I couldn’t do it with shapes because it downgrades the quality and they get pixelated. So I went with another common practice and added them as a background image on a sheet. The technique is originally explained by The Data School in this blog post.

You create two new calculated fields called the X-axis and Y-axis, and give them the value of one. Add them to rows and columns and switch the default aggregation to average. Then turn on opacity by making it 0% and add the desired field to the details and filters panel for the changing effect (in this case it was recipes). Hop on to the map / background images menu, add the picture you’d like to have for a given recipe and set it up the following way:

Backgound image setting

In the options menu, lock the aspect ratio, and add the filter setting to only show this picture when the desired recipe is selected. Then repeat the same process for all the items you have in your dataset.

The only thing left is adding the hidden filter pane. For that, I use a floating vertical container and add a show & hide button. You can customize the buttons if you’d like to, any png images can be used for this purpose, or you can even draw one yourself as I did. I set the color of the filter pane white and lowered the opacity to 34% so that it has this overlay style and the picture is still showing up under it. There you have it, your very own cookbook in Tableau!

Gif of the final result

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.