This week’s Makeover Monday was a great one about sleep and youths. I am going to do my sketch in Tableau this week by making several different charts to play around with the data. My tool for this week is Tableau as there are a few things that I want to try out using Tableau. I did download and install the new release of Tableau Public which has animations, though I am not sure I will use it. The below is the original visualization, which uses a table to present the data. The visual is simple and easy to understand, however it requires reading each line to understand and because of the table format it makes quickly comparing values a more difficult task than it needs to be.
The first step is examining the data to see if there are any transformations or calculated columns needed, Tableau verbiage. The original data had three variables; Grade, Hours Averaged, and Hours Needed. The original visual had a deficit variable which was not present in the data. A quick calculated field to do was the Deficit variable, Hours Needed minus Hours Averaged. The second added variable is rank_cat, which I was going to use to sort the data by Grade. When I dropped Grade into the sheet the sortation was ABC, so I looked at the data and saw that the Hours Averaged was descending in relation to the Grade. So, I thought I could use Rank to help put the data in the right order on the visual.
After having created rank_cat I found that I could manually sort everything, which is what I ended up doing. With a small number of categorical values this was a simple task. A large data set may require something more in line with the rank_cat calculated field.
There are a lot of visuals that are using bars within bars and it is something that I have wanted to try. This data set lends itself to being able to use this visual. The steps are below, courtesy of Eric Parker originally posted on Decisive Data. These steps are directly pulled from Decisive Data.
1) Connect to your data source and bring a measure onto the rows shelf.
2) Bring your first measure onto the columns shelf to create a standard bar chart.
3) Drag your second measure into the view and hover over the first measure’s axis until you see two green rulers stacked one on top of the other, then drop the second measure onto the first measure’s axis.
4) Remove the Measure Names field from the Rows Shelf and drop it onto the Color Tab on the Marks Card to distinguish the two different measures with different colors and allow them to stack one on top of the other.
5) Not only do we want the two measures two have different colors, but we also want the two measures to be different sizes. In order to accomplish this we need to grab another instance of the Measure Names field from our Dimensions List and drop it on the Size Tab in the Marks Card.
6) You’ll notice that the two measures are now distinguished by different colors and sizes, but are stacked on top of one another. In order for them to both start at the zero point on our y-axis, we need to select the Analysis Tab in the Toolbar, hover over the Stack Marks breakout, and turn stack marks off.
7) Now, you should have a stacked bar chart! All that’s left for you to do is adjust which measure is in the foreground and background by swapping the measures on the Measure Values card, and edit the widths/colors of the bars.
Moving to the Dashboard as I wanted only one visual that was nice and clean with the information needed. Next step was finding the right font, which I found on DaFont. Then I really wanted to use Tiled Containers rather than Floating, my usual Tableau method, because of a great video I saw on youtube by Curtis Harris, youtube link. It was a really great watch on how to organize your items so they don’t get lost.
For the font, I did the font in PowerPoint and snipped it as an image because loading custom fonts onto Tableau Public does not tend to have great results.