Henrique Dallazuanna schrieb:
Try this also:

pmax(test - 1, 1)

O
test  <- c(1,3,5,7,9,11,12,13,14)
test
test <- pmax(test - 1, 1)
test

This works for 1
what about if  I would dec 11: to 14  to close the gap between 9 and 10 ?
I did not find the answer with the help file

Thank you Knut

______________________________________________
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.

Reply via email to