Thanks! I've learnt something there!
Steve
_
We want to hear all your funny, exciting and crazy Hotmail stories. Tell us now
__
R-help@r-project.
Try this:
for (i in seq(nrow(index))) {
assign(paste(model, "_mean_",index$year[i], index$month[i], sep=''),
mean(get(paste(model, index$year[i], index$month[i],
sep=''))[,3]))
}
On Mon, Feb 1, 2010 at 11:49 AM, Steve Murray wrote:
>
> Dear all,
>
> I am trying to calcul
Dear all,
I am trying to calculate the mean of one column for many data frames. The code
I am using is as follows:
> for (i in seq(nrow(index))) {
assign(paste(model, "_mean_",index$year[i], index$month[i], sep=''),
mean(get(paste(model, index$year[i], index$month[i], "[,3
3 matches
Mail list logo