I've been trying to incorporate LINESTX into my reporting but keep running into errors when modifying the filter context.
To create a minimal reproducible example, I've loaded a data table like...
jeffrey_wang
Power BI Team
3 years agoWhen you add a filter on a single [ID], VALUES(Data[ID]) returns only that ID which is not what you want. Change to CalculateTable(Values(Data[ID]), All(Data[ID])) to remove the filter on the ID column but keep all other filters. If you always want to calculate the coefficient based on all IDs, simply use All(Data[ID]).