1. This dashboard is inspired by Andy Kriebel's latest Monday Makeover and a question in the comments by Tarik:
    http://vizwiz.blogspot.com/2014/07/footballrevenue.html

    The main features are:
    - Lollipops vertically arranged to use the same revenue axis + top N team highlights.
    - Pie Charts with dynamic top N teams + the rest in a single group.
    - Box Plots as visual stats summaries.
    - Pareto Chart for comparing the Top N teams' share of the overall revenue, a different view from the pie charts. Given a percentage, we see how many top teams are sharing it.

    There are a few touch-ups that might be worth mentioning:
    - Judiciously picked colors such as Spanish red and yellow, British blue and Wimbledon green.
    - Made the pie clockwise by sorting the revenue (at Andy's suggestion). "Others" is always the last slice no matter how big a slice it is.
    - Added percentage along with team names to the pie label. Tableau 8 makes this easy!
    - Made "Others" disappear when N reaches 19.
    - Made sure all the slices have distinct colors by setting the default. Tableau curiously allocates duplicate colors in a pie and made them next to each other.
    - Let "Others" label dynamically show the number of teams in it.

    The insights I gained from the comparison are:
    - The Premier League revenue are more evenly shared among all the teams than those in La Liga. That's probably why the former is way more exciting! It makes the teams more competitive. From the Pareto Chart, we see that the top 2 teams in La Liga almost grabbed 50% of the total revenue while in Premier League, it's the top 9 teams.
    - I didn't realize that Tottenham got more revenue than Arsenal. If we have the profit data, I would like to see who is the most profitable team in absolute number and in ROI.

    The dashboard is too wide to be embedded here. This is the external link: http://t.cn/RPUS3yS

    0

    Add a comment

  2. Need of rolling calendar

    As I stated in an earlier post, a rolling calendar is a better visualization tool than monthly calendar, especially for non-financial and dynamic data monitoring.

    But its design is not so obvious using Tableau. Here I am going to lay out step by step the design of a rolling calender. By calendar, I mean a calendar based heat map.

    A 5-week range is exactly 35 days. The judicious choice is such that it covers any month's length. And a monthly calendar is just a subset of it. However you can pick any window size, greater or smaller than 35 days. And you can make it a parameter if you wish.

    Step 1. Filter design

    The rolling calendar is by default set to the latest 5 weeks of the report date, not the system time. On the other hand, it must also allow a user to check any historical data in an arbitrary 5-week window.

    A calendar grid is not as flexible as axis-based charts. That's the reason we chose to make the window size fixed.

    Basically, there are need for 2 date filters. Upon a switch, we can filter dates to be either the default last 5 weeks or any 5 consecutive weeks. Some may ask that, doesn't the any 5-week filter include the last 5 weeks? Unfortunately, an arbitrary (parameterizable) date range filter can't be made default to the latest date in Tableau.

    The two-option date range filter is a technique I shamelessly borrowed from Andy Kriebel's post:

    In Andy's design, the two options are: full date range and an arbitrary limited date range. In axis-based chart, he has got the luxury of using two options of vastly different scales. But in calendar grid, it's much less flexible.

    Step 2. Selector design

    There are two modes to select: the last 5 weeks or any 5 weeks. So we need a binary parameter like this:
    [Select a filter]:
    True:Last 5 weeks
    False:Pick an end date for any 5 weeks


    The first one is the default option. I use the following calculation to get the last date in the report dynamically:

    LastDate=rawsql_date("select max(report_date) from log_data_table")

    In the illustrative example below, I defined LastDate using a fixed date because the workbook is not connecting to any relational database.

    The date range filter to get the last 5 weeks is:
    Date>=LastDate-34 and Date<=LastDate


    Then we need to duplicate the data source, and use Date of the second data source as the date filter. To be exact, use it as the end date for the date filter. Make sure that the date is continuous.


    In Andy's selector design, he qualified his selection logic as magic. It took me to the top of Santa Cruz mountain to crack that magic while on a weekend hiking trip. I thus formulated my own logic which is non less magic. Do remember to set the filter to be at least 1.


    Int(
    ([Select a filter] and
    min([REPORT_DATE])>max([Last Date])-35)
    and
    max([REPORT_DATE])<=max([Last Date]))
    or
    (not([Select a filter]) and
    min([REPORT_DATE])>max([Sheet2 (CalendarTest) (copy)].[Date])-35)
    and
    max([REPORT_DATE])<=max([Sheet2 (CalendarTest) (copy)].[Date])
    )



    Step 3. Calendar design

    Again, please refer to Andy's post for a heat map calendar design. The difference here is, instead of using week numbers that will leave some gaps between the years around January 1st, I use a technique that is using the first day of the week as the week index. So we will get a continuous grid of weeks. It is done by defining a calculated field: [Week Of] using the formula such as

    Datetrunc('week',Date)



    Step 4. Dynamic Title

    The rolling calendar is limited in displaying its date range. In monthly calendar, we can handily display month in the title. In our rolling calendar, we need a dynamic title to show the date range in the calendar. Thus I created two calculated fields for the start date and the end date in the view:



    -#FilterEndDate:
    if [Select a filter] then max([LastDate])
    elseif max([Sheet2 (CalendarTest) (copy)].[Date])<=max([LastDate])
    then max([Sheet2 (CalendarTest) (copy)].[Date])
    else max([LastDate])
    end

    -#FilterStartDate:
    [FilterEndDate]-34

    Drag -#FilterStartDate and -#FilterEndDate into the detail area first (not in the detail, but under it). In the Title Editor, we need to insert a line like this:
    Date Range: <AGG(FilterStartDate)> - <AGG(FilterEndDate)>

    Then we get a dynamic title showing the date range in sync with date slider picker. Note that we have to set the default date format for both FilterEndDate and FilterStartDate.

    The result

    And voila. The same technique can be applied to the design of line/bar charts with a fixed-size rolling time window that default to the latest date, even after a server refresh.


    0

    Add a comment

  3. It's common that in one workbook we have multiple tabs. One of the tabs is supposed to be the cover tab or the default tab. We need a way to define or select one tab as the cover tab. Tableau always makes the one I am working on as the cover. That's not correct. I had to select the correct one and republish.

    It's so often that I touch and update different tabs, and then publish. Most of time, I found that my working tab is published as the cover. That's bad for productivity.

    I would suggest a solution as follows:

    By default, make the leftmost tab as the primary view just like in Excel.

    So, in this URL for views, it directs users to the primary view/tab.
    http://server/views/workbookname

    In this way we add a finer sense of hierarchy in the information path:
    server>views>workbook>tab
    instead of server>views>tab

    If there is a need for setting up a different cover tab, this page could be used to let us assign a primary view/tab.
    http://server/workbooks/workbookname

    0

    Add a comment

Blog Archive
Loading
Dynamic Views theme. Powered by Blogger. Report Abuse.