I can build the weighted average via quick measure
Average of columnA weighted by weight per Id =
VAR __CATEGORY_VALUES = VALUES('table'[Id])
RETURN
DIVIDE(
SUMX(
KEEPFILTERS(__CATEGORY_VALUES),
CALCULATE(AVERAGE('table'[columnA]) * SUM('table'[weight]))
),
SUMX(KEEPFILTERS(__CATEGORY_VALUES), CALCULATE(SUM('table'[weight])))
)
But my columnA has some blanks. How can I exclude these blanks from the weighted average?