Forum Discussion
Anonymous
3 years agoNot applicable
Average By Columns with Filter and Dates
Hello, I have many columns and I would like to average using a filter and certain columns. So I want the "Value" field to be the average by Analyte, but only when AnalyteType = "Lab", and also only f...
lbendlin
Super User
3 years agoAvg = calculate(AVERAGE('Table'[Value]),'Table'[AnalyteType]="Lab",'Table'[DateEntered]>TODAY()-45)
Note that your sample result of "2" is not valid.
Anonymous
3 years agoNot applicable
This doesn't have "Analyte" in the formula, even though we want the final values averaged by analyte (as shown in the "Avg" column in my example.
I tried this equation and it isn't giving the correct values. Thanks.