MCSimMod
is an R package that facilitates ordinary differential equation (ODE) modeling. Many physical and biological phenomena can be described using mathematical models based on ODEs, and several example ODE models are described in "vignettes" included with the MCSimMod
package. MCSimMod
allows one to perform simulations for ODE models that are encoded in the GNU MCSim model specification language using ODE solvers from the R package deSolve.
Documentation is available at https://usepa.github.io/MCSimMod.
To work with MCSimMod
, the package deSolve
must be installed.
install.packages("deSolve")
As a prerequisite for installation on a Windows operating system, be sure to install RTools. RTools includes utilities that compile C source code for use in R. Installation of RTools is not required when using MCSimMod
on a Unix operating system.
To install the latest stable version of MCSimMod
from CRAN, use the command:
install.packages("MCSimMod")
For the latest development version, install from GitHub using devtools::install_github()
. If the package devtools
has not already been installed, use install.packages("devtools")
. Then, install MCSimMod
using the following command:
devtools::install_github("https://github.com/USEPA/MCSimMod.git", build_vignettes = TRUE)
Alternatively, one can install MCSimMod
from a compressed "tarball" file. For example, if you have a compressed tarball file named MCSimMod.tar.gz
, use the following command:
install.packages("MCSimMod.tar.gz", repos = NULL, type = "source")
To learn about the MCSimMod
package and how to use it, check out the vignettes.
browseVignettes(package = "MCSimMod")
To report an issue with MCSimMod
, please use the issue tracker.
GNU General Public License 3.0
If you wish to contribute to development of MCSimMod
, first clone the MCSimMod repository. Then, start an R session and set the current working directory to a directory within the repository. To document, build, install, and test the package, use the following commands.
devtools::document()
devtools::build()
devtools::install()
devtools::test()
covr::report(file = "coverage_html/index.html")
You can also issue these commands from a Windows or Unix command line terminal as follows.
R -e "devtools::document()"
R -e "devtools::build()"
R -e "devtools::install()"
R -e "devtools::test()"
R -e "covr::report(file = 'coverage_html/index.html')"
To maintain a consistent format for all MCSimMod
source code, we use the styler package to format R code. Note that we use a specific version of the package.
# Install version 1.10.3 of the styler package.
install.packages("styler", version = "1.10.3")
# Apply styler format conventions to all files in the package.
styler::style_pkg(".")
A check is added in continuous integration to ensure that the code conforms to formatting conventions. If it does not, the style check will fail.
The United States Environmental Protection Agency (EPA) GitHub project code is provided on an "as is" basis and the user assumes responsibility for its use. EPA has relinquished control of the information and no longer has responsibility to protect the integrity, confidentiality, or availability of the information. Any reference to specific commercial products, processes, or services by service mark, trademark, manufacturer, or otherwise, does not constitute or imply their endorsement, recommendation or favoring by EPA. The EPA seal and logo shall not be used in any manner to imply endorsement of any commercial product or activity by EPA or the United States Government.