EDPM code that went into MetricsMATR 2008