Description Usage Arguments Value Examples
View source: R/simulate_data.R
This function simulates data for a map of the European Union
(EU) made by eumaps::make_map()
. The data is drawn from a uniform
distribution. It creates a tibble. You can pass the column member_state
to the member_states
argument of create_palette()
and the column
value
to the values
argument of create_palette()
.
1 |
date |
String or date. Optional. If not |
min |
Numeric. Required, has a default value. The minimum value to use
for the uniform distribution. The default value is |
max |
Numeric. Required, has a default value. The maximum value to use
for the uniform distribution. The default value is |
missing |
String. Optional. A vector of member states names. The data
for these member states will be coded as |
This function returns a tibble
with 3 columns: member_state_id
,
member_state
, and value
.
1 2 3 4 5 6 7 8 9 10 | # using the default values
data <- simulate_data()
# using all options
data <- simulate_data(
date = "2015-01-01",
min = 0,
max = 1,
missing = c("France", "Germany")
)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.