Pages

Wednesday, August 27, 2014

Publish Survey Results with Tableau

I feel a little guilty about this one as at the time I was asked this question I didn't realize this was possible. This was a while ago so hopefully my smart student got it all figured out anyway :)

Whenever we are publishing survey results we usually want to present aggregated data (average, median, min, max, etc.) and make sure the responses cannot be traced back to the individuals. Think about your employee engagement survey, salary surveys, etc.

Let's have a look how this can be easily done with Tableau. As an example we will take course satisfaction survey. We gather individual responses as per made-up data below:


We want to display the average rating per course for this instructor, which might look like this:
Now this is great except the end-user looking at this chart might become curious about the individual student ratings. Let's assume we don't have much security around the workbook / server. We might even want to publish this view on Tableau Public. Let's also assume that the original data was in the spreadsheet and we have created a Tableau extract and used that as a data source. If our smart end-user wants to see the details, they can use the 'view data' option on the server and download the full set of data as .csv file.

What we really want, is to only include the summarized data in the extract.
Here is the trick:

1. In the data Window, right-click on the dimension you want to hide (in our example 'Name').
2. Make sure the default aggregation on the rating field is set to 'average' (right click on 'rating' in the data window, select 'default properties', aggregation 'average'). Note, the default is usually sum but in our example we want to show the average rating.
3. Create an extract with the option 'Aggregate data for visible dimensions' and viola!



Now the detailed information is no longer included in the extract, so it is safe to publish and distribute; you can even put it up on Tableau Public.