Displaying 2 results from an estimated 2 matches for "mrunoff_207104".
Did you mean:
mrunoff_207101
2010 Jan 22
1
Looping multiple dimensions
...ay by which I can extract each of the third dimension of these grids (1:12) in turn, along with the first and second dimensions, to create new objects in the following style:
#2071
mrunoff_207101 <- mrunoff_5221[,,1]
mrunoff_207102 <- mrunoff_5221[,,2]
mrunoff_207103 <- mrunoff_5221[,,3]
mrunoff_207104 <- mrunoff_5221[,,4]
mrunoff_207105 <- mrunoff_5221[,,5]?? ...(etc. - up to [,,12])
#2072
mrunoff_207201 <- mrunoff_5222[,,1]
mrunoff_207202 <- mrunoff_5222[,,2]
mrunoff_207203 <- mrunoff_5222[,,3]
mrunoff_207204 <- mrunoff_5222[,,4]
mrunoff_207205 <- mrunoff_5222[,,5]? ...(et...
2011 Jan 17
2
Summing data frame columns on identical data
...the following error: "Error in Ops.data.frame(mrunoff_207101[3], mrunoff_207102[3]) :
? + only defined for equally-sized data frames".
Here is what I'm attempting to do:
> arunoff_2071 <- cbind(mrunoff_207101[1:2], (mrunoff_207101[3] + mrunoff_207102[3] + mrunoff_207103[3] + mrunoff_207104[3] + mrunoff_207105[3] + mrunoff_207106[3] + mrunoff_207107[3] + mrunoff_207108[3] + mrunoff_207109[3]))
Is there an easy way of summing based on congruent values in columns 1 and 2? The only way I can think of would be to use merge, but this would involve doing this for every pair of data frames...