I have a simple reducer that computes the average by doing a sum/ count. But I want to output both the average and the count for a given key, not just the average. Is it possible to output both values from the same invocation of the reducer? Or do I need two reducer invocations? If I try to call output.collect() twice from the reducer and label the key with "type=avg" or "type=count", I get a bunch of garbage out. Please let me know if you have any suggestions.

Thanks,

Shirley

Reply via email to