2021 Call for Code Awards: Live from New York, with SNL’s Colin Jost! Learn more

Analyze loan transactions with Cognos Analytics

IBM Cognos® Analytics is a business intelligence solution that empowers users with AI-infused self-service capabilities that accelerate data preparation, analysis, and report creation.

This tutorial will showcase Cognos Analytics on IBM Cloud Pak® for Data. This version of Cognos Analytics contains AI-infused features, such as:

  • An embedded natural language assistant that allows you to ask a question about your data to gain quick insights.
  • A forecasting tool to discover and model trend, seasonality, and time dependence in your data.
  • Insight analysis that can help detect and validate any important relationships and meaningful differences in individual visualizations.

Learning objectives

In this tutorial, you will learn how to use Cognos Analytics to gain insights into loan transaction data from a bank.

This tutorial serves as a complement to the Modernize your bank loan department case study. This tutorial will focus on the role of the business analyst and how Cognos Analytics can be used to gain insights into:

  • Identifying key drivers for predicting loan risk
  • Visualizing how loan amount and loan length can effect risk
  • Predicting future loan amounts


To follow along with this tutorial, you need to have access to an IBM Cloud Pak for Data cluster that has IBM Cognos Analytics installed and provisioned.

Estimated time

Completing this tutorial should take about 30 minutes.


  1. Launch Cognos Analytics
  2. Upload data files
  3. Create a dashboard
  4. Create a spiral visualization to show main drivers to determine credit risk
  5. Create a list visualization to show the effect of loan amount and loan length on risk
  6. Create a data module
  7. Create a history visualization

Launch Cognos Analytics


Upload data files

From the Cognos Analytics main menu, select the option to Upload files.


Upload the following data files to your My content folder:


Create a dashboard

  1. From the Cognos Analytics main dashboard, select the + icon in the lower-left corner and select Dashboard. Accept the default template and click Create.

  2. Once the dashboard panel appears, click Select a source.

  3. From the Add a data source dialog, navigate to your My content folder and select the german_credit_risk_data.csv file.


You should then see a blank canvas to create your dashboard.


From the image above:

  • [1] The data module currently associated with the dashboard
  • [2] The resources included in the data module
  • [3] The dashboard canvas
  • [4] The tabs defined for the dashboard

To create your dashboard, you will need to become knowledgeable with the numerous tools available from icons and pop-up menus.


The image above:

  • [1] Toggles you between edit and preview mode.
  • [2] Toggles display of the resouces (data objects) in the data module.
  • [3] Shows an example of one of many drop-down menus associated with data objects.
  • [4] Displays the relationship between all the visual objects on your dashboard. Objects with the same number are related.
  • [5] Toggles full-screen mode on and off.
  • [6] Toggles display of the filter panels.
  • [7] Displays the fields associated with the selected visual object.
  • [8] Displays the properties associated with the selected visual object.
  • [9] Shows filters that can be applied to dashboard visual objects. Filters can be set for all dashboard tabs (left side) or for the current tab (right side).

The types of visualizations available include those shown below.


Create a spiral visualization to show main drivers to determine credit risk

Our first visualization we will be a spiral, which will rank how important each of the drivers are in determining credit risk.

  1. Select the PredictedRisk field in the german_credit_risk_new_apps_scored file in the data source list and drag it onto the canvas. The toolbar at the top of the window is active for the currently selected visualization. For convenience, you can click on Undock toolbar to have the toolbar snap next to the selected visualization.


  2. Click on the anchor icon to bring up the toolbar for the visualization, then click on the Change visualization tool. In this particular case, the default visualization choosen for the data type is a table. We need to change this to a spiral.


  3. From the pop-up menu, click All visualiztions to open the list of available visualizations. Select spiral.


  4. From the visualization toolbar, click on the Edit the title icon and set the title to Greatest predictors of Risk.


  5. Use the box sizing tools to position the box in the upper left-hand corner of the dashboard.

  6. Use the Expand/Collapse button in the upper right-hand corner of your visualization to view in expanded mode or to collapse the view in your dashboard canvas.


As you can see, the spiral visualization ranks the drivers that influence the target field – Risk.

NOTE: Click the Filters button to turn on/off the filters displayed at the top of the window. Click the collapse icon in the top-right corner to collapse the visualization.


Use the Fields tab to change what the visualization is based on and use the Properties tab to modify the look and feel of the visualization.


Create a list visualization to show the effect of loan amount and loan length on risk

Next, we will show what effect loan amount and loan duration have on credit risk.

  1. Start by clicking on the + icon in the tabs bar to create a new tab where we can create our visualization.

  2. Click the Visualizations icon in the left navigation bar and select the Line graph icon and drap it onto the canvas.

  3. With the new visualization selected, click on the Fields tab.

  4. Going back to our resource list, from the german_credit_data file, drag LoanAmount to the x-axis field, LoanDuration to the y-axis field, and Risk to the color field.

NOTE: You can also drag the items directly to the designated spots displayed on the List object.


This initial graph layout is too compact, and a warning icon is displayed in the upper-right corner. The warning states that multiple items had to be clipped and that we should apply a filter to show less data.

Make the suggested adjustment by clicking the menu for the Loan Amount field, then enabling the Auto-group option.


This will result in a much more useful chart.


We can see that the least risky loans are for small loan amount that have a large loan duration.

  • To get more insights into the data, click on the light bulb icon in the upper-right of the canvas.


  • If desired, you can use the Change color palatte option under the Properties tab to change the line colors.


  • To finish off your visualization, change the title of the visualization to Loan amount and duration vs risk.

  • Click the Save icon in the top menu to save your dashboard and save the dashboard in the My content folder.

Create a data module

The historic data in the history_business_payloads.csv file contains a timestamp field. For our next visualization, we will show time in a different format. To do this, we need to modify the data by creating a data module.

  1. Click the + icon at the bottom of the left-side menu bar and select Data Module.

  2. For the source data, select the history_business_payloads.csv file from the My content folder, then click OK.

The data module panel allows you to combine data sets and define relationships. For our case, we will split the timestamp field into new fields that represent each of the timestamp segments.

From the Grid tab, select the history_business_payloads.csv entry in the source list.


  1. Scoll over to the timestamp field and click on the header to bring up the action menu. Select the Split option.


  2. Select Year, Month, Day, and Hour.


  3. Click Next > OK to complete the process. The new table will include the new fields.

  4. Click the Save icon in the top menu to save your new data module. Name the data module history-data-module and save it in the My content folder.

Create a history visualization

  1. Click the + icon at the bottom of the left-side menu bar and select Dashboard. Accept the default template and click Create.
  2. For the source data, select the history_data-module data module from the My content folder.
  3. For this visualization, we will use the Assistant feature to help us create our initial graph. Click the Assistant icon in the left-hand tabs to bring up the query panel.


  4. In the query field, enter show me loan amount by date. It will return a line chart that you can then drag and drop onto your dashboard canvas.


If you click on the Fields tab, you will see it selected timestamp as the x-axis. To make the chart less cluttered, we can use our new date fields to summarize load amounts on a daily basis.

  1. Start by going back to the tree view by selecting the Sources tab in the left-side menu.
  2. Remove timestamp and add Year, Month, and Day.


Since the LoanAmount values fall into a small range, let’s change the value of the y-axis origin.

  1. Click on the Properties tab, select Visualizations, then expand the Chart options and disable the Value axis show zero origin option.


  2. Click on the Forecast icon located at the top-right of the chart. When enabled, Cognos Analytics will attempt forecast future loan amount values.


  3. Click on the light bulb icon at the top-right of the chart to enable insights. For this chart, it will show the average loan amount and highlight some values detected as anomolies. If you mouse over the highlighted nodes (filled-in circles), you can see the detailed warning.



In this tutorial, we detailed how to use some of the new AI-infused features in Cognos Analytics to help visualize loan transactions. You learned how to use the data module feature to prepare and clean the data. You learned how to create and customize charts and graphs to help explain credit risk and produce forecasting models, and shown examples of how Cognos Analytics insights can help identify anomalies in your data.