Using Bookmarks to Create Guided Analysis in TIBCO Spotfire


This week we will start a tip of the week arc where we introduce the new features of TIBCO Spotfire version 3.3. In this tip we will focus on how to use the updated Bookmark capabilities to create Guided Analytic Applications.  There are many other useful capabilities of bookmarks, like collaboration, which will be discussed in future tips.

 

Bookmarks were updated in version 3.3 to support the capturing of properties as well as page layouts and visualization properties. These concepts come in very handy  when you want to ‘guide’ the user through an analytic process. Suppose we define a visualization which includes a document property in the expression used on one of its axes. We can modify the property values and capture bookmarks so that we can easily revert back to common configurations. 

For example, suppose we have a Bar Chart which will display the yield of various mortgage amounts over 10 years, using an annual interest rate of 8%.

 


As the author of the file, you may want the user to see what the total yield would be both at 8% and at 5%, and you would rather not take up the real estate to show 2 separate visualizations.  Using 3.3 Bookmarks, you can update the document property which contains the interest rate as part of the yield calculation, and then take a snapshot of that visualization, including the property. You can then update the property to a new value, and take another bookmark.


Once this is done, we can now go into a Text Area and add Action Controls which will trigger the bookmarks as part of a guided analysis. When adding the bookmark to the Action Control, we want to add the ‘Properties’ component of the bookmark only. This will update the property to the value when the bookmark was captured.

 
We can repeat this process and add another Action Control which will apply the second bookmark as shown below.
 

In addition to using properties as part of Bookmarks, we can also capture page layouts and visualization properties. This will allow us to accomplish certain tasks which previously required a Script Control.  For example, in the example above, if we wanted to update the visualization’s title to display either ‘Total Yield for 5 percent interest’  or  ‘Total yield for 8 percent interest’ when the appropriate bookmark was applied, you would, as the author, update the visualization title to the correct title before capturing each bookmark. (for example, update the title to be 5 Percent Yield when you capture the 5 percent bookmark and then update the title to be 8 Percent Yield when you capture the 8 percent bookmark). Then when you apply the bookmark in the Action Control, you will add in both the ‘Properties’ and ‘Page Layout and Visualizations’ features.
 

 

In addition to visualization titles, the new bookmark features allow you to take the same approach to any visualization property.  A good example would be to create bookmarks to turn the trellis feature either on or off.
 

 

Another popular use for capturing the visualization properties in a bookmark is to create an affect where you are only displaying certain visualizations on the page when the user clicks on a link, ideally as part of a guided process.

Take a look at the example below, which shows some text in a text area and then a Combination Chart which shows the sum of sales from each sales representative.


By capturing bookmarks , we can now create an action link (which shows up as a link in the text area to the left) that will change the visualizations on the right, including new instructions in the text area, and then a Combination Chart which shows sales predications and quotes for each sales team.

 

A key point to mention is that, when doing this approach, the visualization types have to be the same. So, in the example above, the two visualizations used in the bookmark were always a Text Area and a Combination Chart…this would not work if we tried to have a different visualization at one point.  You can update any property in a visualization, like the title, the data table used, the axis expressions, etc..., but the visualization type needs to remain the same.