Description Usage Arguments Value Examples
View source: R/fullSimulationApp.R
This function runs the entire simulation by wrapping all other functions into a single function, accepting all default customization options
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | fullSimulationApp(
data,
shp_reg = NULL,
shp_app = NULL,
convertFromUTM = FALSE,
dat_sample = NULL,
landcover_varname,
reg_formula,
landcover_invasive,
landcover_susceptible,
x_coords_varname,
y_coords_varname,
spread_rate,
birdcell,
simlength,
simulation_count = 100,
dep_var_modifier = NA,
unit_converter = 1,
covar_adjustment = 1,
zero_break = FALSE,
outlier_value = NA,
dep_var_plot_label = "mm/yr",
dep_var_plot_label_cumulative = "mm",
line_plot_labels = c("Water yield", "Recharge"),
line_plot_positive_vals_only = TRUE,
line_plot_axis_label = "mm/yr",
landcover_label_invasive = "Invasive",
landcover_label_susceptible = "Susceptible",
preview_plot_scalebar_position = "bottomright",
preview_plot_scalebar_unit = "km",
preview_plot_scalebar_dist = 10,
priority_plot_scalebar_position = "bottomright",
priority_plot_scalebar_unit = "km",
priority_plot_scalebar_dist = 1,
num_cores = parallel::detectCores() - 1
)
|
data |
|
shp_reg |
character string specifying layer (.shp) filename corresponding to |
shp_app |
character string specifying layer (.shp) filename corresponding to |
convertFromUTM |
logical. Set to |
dat_sample |
numerical. If specified, will take a sample of |
landcover_varname |
character string specifying the landcover variable from |
reg_formula |
regression formula to be used, as in |
landcover_invasive |
value. Numerical or character value of the invasive landcover. |
landcover_susceptible |
value. Numerical or character value(s) of the susceptible landcover(s). If more than one susceptible landcover, provide a vector |
x_coords_varname |
character string. Name of the x-coordinate variable in |
y_coords_varname |
character string. Name of the y-coordinate variable in |
spread_rate |
numerical. Value between 0 and 1 indicating the annual spread rate of the invading landcover. |
birdcell |
numerical. Value between 0 and 1 indicating the probability a random cell can be invaded, regardless of adjacency to existing invaded pixels. |
simlength |
integer. Number of years the simulation should run. |
simulation_count |
integer. Length of simulation bootstrap. |
dep_var_modifier |
numerical. A scalar to optionally return a list of rasters with modified dep_var rasters (e.g. multiply water yield rasters to obtain recharge rasters) |
unit_converter |
numerical. A scalar to optionally modify the values of the resulting dependent variable (and modified dependent variable, if present) to convert units (e.g. mm/yr to gal/acre/day). Default value is |
covar_adjustment |
list. List specifying change in covariate values. See ?gls_spatial_predict. |
zero_break |
numerical. Should the priority plots have a breakpoint at 0 if values are both negative and positive? |
outlier_value |
numerical. Cutoff value for outliers in the priority plots. |
dep_var_plot_label |
character. Label for the dependent variable used in plots. |
dep_var_plot_label_cumulative |
character. Legend title for the cumulative change priority plot (also applied to modified values, if |
line_plot_labels |
character vector of length 1 or 2, for dependent variable and modified dependent variable if provided, for the line graph. e.g. |
line_plot_positive_vals_only |
logical. When plotting the line graph, should the negative values be removed when aggregating by year? |
num_cores |
numerical. Number of cores for parallel processing, max 5 |
data_as_directories |
logical. |
shp_reg_directory |
character string specifying directory of shapefile outlining the area of |
shp_app_directory |
character string specifying directory of shapefile outlining the area of |
A list of all objects returned by the individual functions
1 | TO DO
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.