2 Replies Latest reply: Mar 12, 2012 5:41 AM by Jörg Nold

# Problem with calculation for SPC

Hello,

I have to replace a SPC-analysis with Qlikview, which at the moment is implemented with Excel. But I can't get Qlikview to calculate upper and lower bounds as I want it, to show these bounds in a chart. For simplification I made an example with a "Straight"-Table, but I need it in a chart.

1. Values are sorted in a defined manner.

2. I have to calculate the difference between the actual row and the following row => no problem

3. I need the average value of the column I've created under point 2 in further column => there is my problem.

So in my attached example I need the calculated average from "Spannweite" in a column "Avg Spannweite", so I can make further calculations to get my upper and lower bounds.

Qlikview Version: 11 with Update.

I hope you understand my problem.

Kind regards

Peter Hübschen

• ###### Problem with calculation for SPC

Hi,

Have you tried with Aggr function?

Avg(Total Aggr(Expression,Unique field name))

Can you post the image of the straight table because im using personal edition i cann't open your fiel.

Celambarasan

• ###### Re: Problem with calculation for SPC

Hi,

my formulas look like this, so I use already the aggr-function.

"Spannweite": fabs(Value - below(Total Value, 1))

"Avg. Spannweite": avg(total aggr(fabs(Value - below(Value, 1)), PANo, lfdNo))

Also I've attached a screenshot of my "Straight"-Table example.

Kind regards

Peter Hübschen