cancel
Showing results for 
Search instead for 
Did you mean: 
Community_Admin
Community Team Member
Community Team Member

Analytical Need 

Sometimes we wish to see how we are performing in the last x months and comparing that to the previous parallel period.

For example, we wish to see how we perform from Sep last year to Aug this year and compare it with Sep 2 years ago to Aug last year. 

Modeling Challenge

If we use the period over period mechanism, we will have the period number (even if displayed by text) ordered from the first one, not necessarily ending in the current period.

Solution

In our example we present a view of 12 months back.

We will create the widget with the following definitions:

  1. The x axis is the month (out of the date field)
  2. We will filter the x axis for the past 12 months like so:

 Pick Time Frame and then 2 months. 

Community_Admin_0-1634204328304.png

Image 1. Date filter with 2 months selection

Click on Advanced and change the count to 12 and offset to 0 :

Community_Admin_1-1634204328333.png

Image 2. Date filter with 12 months selection (including this month)

Click OK.

  1. Add 2 values:
  • This Year -  sum([Value]) - the regular formula you wish to calculate
  • Last Year - (sum([Value]), prev([Months in date],12))  - same formula but with a measured value that uses the PREV function which gives you the option to take 12 months back for each of the dimension (Month) values.

You will get this widget:

Community_Admin_2-1634204328264.png

 

Image 3. YoY but with a specific x Axis

But the x axis is misleading because of the year. So we would want to change it to reflect the month name like so:

Community_Admin_3-1634204328355.png

Image 4. Formatting the x axis labels

And now the X axis will look like this:

Community_Admin_4-1634204328384.png

Image 5. Final Widget

12 Months YoY Cube.ecdata

test12monthsYOY.dash

Version history
Last update:
‎10-14-2021 02:39 AM
Updated by:
Contributors
Community Toolbox

Recommended quick links to assist you in optimizing your community experience:

Need additional support?:

Community Support Request