Description Usage Arguments Value Author(s) See Also Examples
Increases 'x' by 'value'. Equivalent to x <- x + value.
1 | addTo(x) <- value
|
x |
Object whose value is to be changed. |
value |
value to add to 'x'; can be negative. |
Returns 'value'.
Charles Dupont authored the inc<- function in Frank Harrell's Hmisc package. Renamed addTo rather than inc as the latter implies "add 1".
See also inc<-
.
1 2 3 4 5 | x <- 2:6
addTo(x) <- 3
x
addTo(x) <- -2:2
x
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.