View source: R/match_numerics.R
| match_numerics | R Documentation |
This function matches the indices of two numeric vectors as good as possible (that means with the smallest possible sum of deviations).
match_numerics(x, y)
x, y |
[ |
An integer vector of length length(x) with the positions of
y in x.
Other vector helpers:
check_numeric_vector(),
check_probability_vector(),
chunk_vector(),
equidistant_vectors(),
insert_vector_entry(),
map_indices(),
permutations(),
split_vector_at(),
subsets(),
vector_occurrence()
x <- c(-1, 0, 1)
y <- c(0.1, 1.5, -1.2)
match_numerics(x, y)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.