search for: max_date

Displaying 2 results from an estimated 2 matches for "max_date".

Did you mean: max_data
2013 May 23
3
Removing rows w/ smaller value from data frame
Hello, I have a column called max_date in my data frame and I only want to keep the bigger values for the same activity. How can I do that? data frame: activity max_dt A 2013-03-05 B 2013-03-28 A 2013-03-28 C 2013-03-28 B 2013-03-01 Thank you for your help -- View this...
2010 Feb 09
1
Aggregate dataframe variables, return more than 2 vars
...id x.decod.1. end 1 1 COMPLETE 2005-08-29 2 2 COMPLETE 2005-08-29 3 3 WITHDRAWAL 2005-08-29 I can get the max date and the id 2 different ways: > do.call("rbind", lapply(split(dat, dat$id), function(x) data.frame(id = x$id[1], max_date = max(x$date)))) id end 1 1 2005-08-29 2 2 2005-08-29 3 3 2005-08-29 OR > aggregate(dat$date, list(USUBJID=dat$id),FUN="max") USUBJID x 1 1 13024 2 2 13024 3 3 13024 (which oddly returns some number of days after 1-1-1970 iso of the max as...