Dear list:
I have the following problem: From a vector like this: vec<- c("mud_1999_area_A", "gravel_2004_area_F") I would like to get the year in a separate vector, such y<- c("1999", "2004") I´ve been looking to grep() but I'm not sure how to do this. Help? Thanks in advance J [[alternative HTML version deleted]]
______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.