encode_value | R Documentation |
Takes a vector and returns an integer that is a product of the prime keys
corresponding to the values in the vector. The second argument takes an
encoding key as generated by make_encoding_key()
. Values can be decoded
using decode_value()
.
encode_value(values_to_encode, prime_key)
values_to_encode |
A vector of values to encode. |
prime_key |
An encoding key, as generated by |
A double, containing an integer value.
make_encoding_key()
decode_value()
# Generate a product equal to 15. encoded_value <- encode_value(c('Mammal', 'Bird'), c(Fish = 2, Mammal = 3, Bird = 5))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.