Anna
Anna

Reputation: 11

Row level average calculation tableau

I need to calculate average in tableau..one equation was sum(var A* varB)/sum(varB)..I have converted it into row level equation as avg((varAvarB)/varB) and it is working fine.but now I have another equation i.e sum(varAvarB)/total(sum(varB)).could some one help me how to convert this into row level average calculation.

Upvotes: 0

Views: 641

Answers (1)

Debayan
Debayan

Reputation: 854

This is a classic scenario where you can leverage Level of Detail expressions in Tableau

read here: https://help.tableau.com/current/pro/desktop/en-us/calculations_calculatedfields_lod_overview.htm

Your expressions would emerge like : AVG([{FIXED [Segment]], [Category]] : SUM([Sales]])}])

You will have greater control over row-level operations using LoD

Please read the link and try it

Upvotes: 0

Related Questions