Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 7790

Calculating Average then using it in another calculation.

$
0
0


Hi,

 

I would be grateful if someone could point me in the right direction - as I'm clearly being daft!

 

I have a report that summaries the  SalesValue measure (which is an aggregate function in the universe)

 

Week 1          £1000

Week 2          £1500

Week 3          £900

I have created a variable TOTAL SALES (sum(salesvalue)) which successfully displays £3400.

I have created a variable for average (Total Sales /3) which displays £1133.33.

 

What is the best way to  create a variable for each week to show the difference between the average (£1133) and the sales for the week i.e Week 1 = +133, week 2=+367, week 3 =-233.

 

Whenever I create this variable (SalesValue-Average) and put it next to week it doesn't calculate based in the total sales (£3400)

 

I'm sorry if this is one of those easy simple things but I am new to WEBI and I'm struggling.

 

Many thanks in advance.

 

Jude


Viewing all articles
Browse latest Browse all 7790

Trending Articles