Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am being asked to reproduce a calculation from SQL and have run into a SQL command VPAR which finds the P-Value of a set of numbers. P-Value is supposed to indicate statistical significance, but I cannot find any reference that can help me in Qlikview, nor can I figure out how to calculate the P-Value in general. Does anybody have any clue how to accomplish this? Here is the code I am attempting to reproduce:
SELECT AVG(quantity) AvgQuantity,
(Avg(date * quantity) - Avg(date) * Avg(quantity)) / VarP(date) AS Slope,
power(((1 / (VarP(date) * (Count(date) - 2))) * (VarP(quantity) - power((Avg(date * quantity) - Avg(date) * Avg(quantity)), 2) / VarP(date))), 0.5) AS SE_Slope into #stats
FROM #data
Thanks,
Aaron
Here it is:
sum(aggr(pow(fabs(Value - avg(total Value)), 2), Value))/count(Value)
See example in attachment
I know its too late 😄 still adding so that it will be useful for others 🙂
TTest_sig() actually gives you the P value. and it always gives you for two tailed. you can just divide it by 2 to get the equivalent one tail number.