How do I get the date diff based on a different column in R
I have a data fame with data like the following:
ID Date Value ----- --------- --------- 001 2012-01-15 8.6 003 2000-05-03
10.1 001 2005-03-30 7.3 1002 2013-07-05 1.4
I am trying to get the initial date per ID and then get the number of
months of each subsequent value for that ID. I can get the min date for
each ID simply enough using aggregate but I am stumped on how to do the
rest.
Any thoughts on how to accomplish this? I am brand new to R so any
pointers would be most appreciated.
TIA!
No comments:
Post a Comment