Monday, February 13, 2012

Weighting to score

I was putting together an evaluation matrix today. This is like a marking scheme for an exam: for each question, you allocate the maximum number of possible marks; in the next column you allocate space to enter the actual mark obtained.

So far, so good. But there's a refinement. Not all questions are equally important so with each question we associate a weight, a number like 1, 2 or 3. Now, what do we do with the weights?

It's obvious: you multiply the actual scores by the weights ... but in so doing you mess everything up: the total changes and when you sum the weighted scores the answer becomes  arbitrary, depending on your choice of weights.

I sat and thought about this: what was the right algorithm ... no, what would even count as a useful solution?

I decided that my inability to instantly solve this problem was obviously diagnostic of incipient Alzheimer's. Finally, after some playing around, inspiration struck.

Multiplying by a set of weights is a kind of local gauge transformation on the answer vector. Scores of zero and 100% need to transform invariantly while other scores are moved around by the differential action of the weights. Following the local gauge transform there is a final scaling to remap the scores into the original range (or any other range of choice).

Easy to implement in Excel - so who says QFT is without a wider significance :-) ...