weighted.mean and tapply (again)
In this simple case you can just coerce directly to a vector like so:
foo <- by(dat, dat$GROUP, function(x) {weighted.mean(x$VALUE,
x$FREQUENCY)})
bar <- as.vector(foo)
but look at the examples for ?by; in particular the use of 'sapply'. Norm
As a general practice, I believe unlist() is preferable. ?unlist explains why. Cheers, Bert Gunter