View source: R/calculate_deltas.R
calculate_deltas | R Documentation |
Function to calculate deltas or differences between two vectors.
calculate_deltas(x, y, absolute = FALSE, round = NA)
x , y |
Numeric vectors. |
absolute |
Should deltas be represented absolutely (all positive)? |
round |
Number of digits to round deltas to. |
Numeric vector
Stuart K. Grange.
# Calculate errors
calculate_deltas(sample(1:5), sample(1:5))
# Absolute
calculate_deltas(sample(1:5), sample(1:5), absolute = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.