I have a zoo with monthly entries. For each month there are many entries,
but only one entry per ticker. To to track the performance of decile
portfolios I want to merge each entry with future dates of itself (i.e.,
lag). For example, here's AAPL

> head(temp[which(temp$symbol=="AAPL1C"),])
       symbol oi          ret           decile
200806 AAPL1C  8710943.20 -1.129018e-01 10
200807 AAPL1C  7540246.46 -2.437297e-03 10
200808 AAPL1C 11366863.59  1.703864e-01 10
200809 AAPL1C  9500119.05 -3.689558e-01 10
200810 AAPL1C   114082.48 -4.406700e-02  1
200811 AAPL1C   723159.24 -1.437163e-01  6

and it's future self

> head(temp.lag[which(temp.lag$symbol=="AAPL1C"),])
       symbol oi          ret           decile
200806 AAPL1C  7540246.46 -2.437297e-03 10
200807 AAPL1C 11366863.59  1.703864e-01 10
200808 AAPL1C  9500119.05 -3.689558e-01 10
200809 AAPL1C   114082.48 -4.406700e-02  1
200810 AAPL1C   723159.24 -1.437163e-01  6
200811 AAPL1C  1006345.25 -1.005402e-01  8

When I try to merge these two, I get the warning (of course) that I can't
merge zoos with duplicate dates.

Is there a way to merge on the "symbol" column, too?

I could lag, convert both back to dataframe, join, then go back to zoo. Is
there a better way?

Thanks!

	[[alternative HTML version deleted]]

