knitr::opts_chunk$set( collapse = TRUE, comment = "#>", table.knit_hooks = function(x) { kableExtra::kable_styling(x, bootstrap_options = c("striped", "hover"), padding = 10) } )
Compare all of the default results from the MEMC model configurations included within the package. This example will show users how to run MEMC model configurations and how to visualize the results.
Start by loading the package.
# This assumes that the package has already been installed, see installation instructions. library(MEMC) # See https://ggplot2-book.org/ for more details on data visualization. library(ggplot2) theme_set(theme_bw())
Take look at the table of package model configurations.
summary(memc_all_configs)
Run all 6 model configurations using the memc_solve
function
# Vector for the time steps times <- seq(0, 600, by = 1) # Solve all the model configurations out_list <- lapply(memc_all_configs, memc_solve, time = times) # Save all of the output in a single data frame for plotting. out <- do.call(rbind, out_list)
Visualize results!
plot(out)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.