Skip to Content
Former Member
May 09, 2016 at 12:45 PM

Trouble with Sum for distinct dimension values



I have a problem which I'm having trouble solving. It's doable in webI but I haven't been able to recreate it in Lumira.


I have 1 dimension ID.

I have 1 measure VALUE.

I am trying to calculate weight which is Sum(VALUE)/Count(ID), but this can't be achieved this simply as one ID can occupy several rows.

So if I have a dataset like this:


  1. 1, 1
  2. 1, 1
  3. 1, 1
  4. 2, 2
  5. 2, 2
  6. 3, 6

The WEIGHT for all of these should be calculated as: SUM(((1+1+1)/3) + ((2+2)/2) + (6/1))

The WEIGHT should therefore be 3.

How can I achieve this in Lumira?
In webi I use Count(RowIndex()) to divide the sum of VALUE with the amount of rows it's presented in via ID. But I can't seem to recreate this in Lumira at all.

Any advice is appreciated.

I am using a .UNX as my datasource and I'm using Lumira 1.29 (upgrading to 1.30 in a very near future).