View source: R/csm_create_data_structure.R
| csm_create_data_structure | R Documentation |
Create a cropping systems model (CSM) data structure
csm_create_data_structure(name, definition, variables, n_dim = 1)
name |
a length-one character vector name of a variable |
definition |
the definition of the data structure |
variables |
a list of the CSM variables (as defined with [csmbuilder::csm_create_variable()]) that are contained within the data structure |
n_dim |
the number of dimensions in the data structure; default value of 1 (i.e. each variable is expected to be a scalar value) |
a list of 'csm_data_structure' objects
# Create variables:
wth_variables <- c(
csm_create_variable("time",
"time of observation",
"days"),
csm_create_variable("Tair",
"air temperature",
"Celsius"),
csm_create_variable("SRAD",
"solar radiation",
"MJ/m2/d"))
# Create weather data structure:
weather <- csm_create_data_structure("weather",
"weather data",
wth_variables,
n_dim = 2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.