Reply To: Can I add a simple calculation to a view

#574
 Frank
Keymaster
  • Topics Started - 74
  • Replies Written - 52

Percentage calculations? Those are easy too!
Following the steps in the previous post – get to the Add Calculated Measure window.

Once there in list on the left side of the window open the Stratum Viewer Functions and then select one of the percentage calcs (I copied some info from the Stratum Help):
Achievement Percent:
Returns the achievement percentage between two measure items — for example, the percent of sales achieved in comparison to the budgeted sales.

The expression for this function is Measure Item 1 / Measure Item 2 with a divide by zero check. The divide by zero check will return null if Measure item 2, the divisor, is zero or null.

The expression syntax includes the names (Data1 and Data2) and captions of the specified measure items.

Recommendations: select a percentage Format String and set Total property to None.

Divide with Zero Check:
#DivideWithZeroCheck([Measures].[Data1 (Daily Sales Amount Wk 38 2014 to Wk 38 2014)], [Measures].[Data2 (Daily Sales Units Wk 38 2014 to Wk 38 2014)])

Divides two numbers with a divide by zero check.
The expression for this function is Measure Item 1 / Measure Item 2 with a divide by zero check. The divide by zero check will return null if Numeric Expression 2, the divisor, is zero or null.

Percent of Change:
#PercentOfChange([Measures].[Data1 (Actual Sales Amount Q1 2013 to Q3 2013)], [Measures].[Data2 (Actual Sales Sales Amount Q1 2012 to Q3 2012)])

Returns the percent of change, also known as the variance percentage, between two measure items or expressions — in this case, the change between YTD sales for two different years.

The expression for this function is (Measure Item 1 – Measure Item 2) / Measure Item 2 with a divide by zero check. The divide by zero check will return null if Measure item 2, the divisor, is zero or null.

Recommendations: select a percentage Format String and set Total property to None.

The one I use most often is Achievement Percentage – how did we do vs. a plan or last year. These measures are one of the most common forms of a KPI or target metric and are good canidates for a Conditional Format (traffic light) and/or an exception view (one that only shows exceptions to some threshold – e.g. all customers for this rep that are more than 15% off of last year, or anywhere the product mix for this customer has changed by more than 10%.)

When using these Stratum makes it easy to include the measures into the calc.

Once you click on the % calc you want in the left side menu it will put that base definition in the right hand part of the calc window.
Next open the Measure group in the left side of the window – this will list the measures you have in your view. Click on the one you want to divide – it will automatically be included into the expression in the right side of the window.
Next click on the measure you want to divide by – it will it will automatically be included into the expression in the right side of the window.

click ok – click Save if your good with results

Done!

CONTACT US

We're not around right now. But you can send us an email and we'll get back to you, asap.

Sending

©2021 KLEO Template a premium and multipurpose theme from Seventh Queen

Log in with your credentials

or    

Forgot your details?