Re: [R] Lag based on Date objects with non-consecutive values

2012-03-20 Thread Sam Albers
On Mon, Mar 19, 2012 at 9:11 PM, Gabor Grothendieck wrote: > > > On Mon, Mar 19, 2012 at 8:03 PM, Sam Albers > wrote: >> >> Hello R-ers, >> >> I just wanted to update this post. I've made some progress on this but >> am still not quite where I need to be. I feel like I am close so I >> just wante

Re: [R] Lag based on Date objects with non-consecutive values

2012-03-19 Thread Gabor Grothendieck
On Mon, Mar 19, 2012 at 8:03 PM, Sam Albers wrote: > Hello R-ers, > > I just wanted to update this post. I've made some progress on this but > am still not quite where I need to be. I feel like I am close so I > just wanted to share my work so far. > > Try this: Lines <- "Date Dis1 1967-06-0

Re: [R] Lag based on Date objects with non-consecutive values

2012-03-19 Thread Sam Albers
Hello R-ers, I just wanted to update this post. I've made some progress on this but am still not quite where I need to be. I feel like I am close so I just wanted to share my work so far. Thanks in advance! Sam On Mon, Mar 19, 2012 at 1:10 PM, Sam Albers wrote: > Hello all, > > I need to figur

[R] Lag based on Date objects with non-consecutive values

2012-03-19 Thread Sam Albers
Hello all, I need to figure out a way to lag a variable in by a number of days without using the zoo package. I need to use a remote R connection that doesn't have the zoo package installed and is unwilling to do so. So that is, I want a function where I can specify the number of days to lag a var