diff --git a/modules/assim.batch/NAMESPACE b/modules/assim.batch/NAMESPACE index e69de29bb2d..bde38b63dad 100644 --- a/modules/assim.batch/NAMESPACE +++ b/modules/assim.batch/NAMESPACE @@ -0,0 +1 @@ +export(pda.mcmc) diff --git a/modules/assim.batch/R/pda.mcmc.R b/modules/assim.batch/R/pda.mcmc.R index 872e2ab9417..67ebe502c93 100644 --- a/modules/assim.batch/R/pda.mcmc.R +++ b/modules/assim.batch/R/pda.mcmc.R @@ -10,6 +10,7 @@ ##' ##' @author Mike Dietze ##' @author Ryan Kelly +##' @export pda.mcmc <- function(settings, params=NULL, jvar=NULL, var.names=NULL, prior=NULL, chain=NULL, adapt=NULL, adj.min=NULL, ar.target=NULL){ # Quit if pda not requested in settings diff --git a/modules/assim.batch/man/pda.mcmc.Rd b/modules/assim.batch/man/pda.mcmc.Rd index 739179f5955..23144047f06 100644 --- a/modules/assim.batch/man/pda.mcmc.Rd +++ b/modules/assim.batch/man/pda.mcmc.Rd @@ -1,17 +1,17 @@ -% Generated by roxygen2 (4.1.1): do not edit by hand -% Please edit documentation in R/pda.mcmc.R \name{pda.mcmc} \alias{pda.mcmc} \title{Paramater Data Assimilation using MCMC} \usage{ -pda.mcmc(settings) +pda.mcmc(settings, params = NULL, jvar = NULL, var.names = NULL, + prior = NULL, chain = NULL, adapt = NULL, adj.min = NULL, + ar.target = NULL) } \arguments{ -\item{settings}{= a pecan settings list} + \item{settings}{= a pecan settings list} } \value{ -nothing. Diagnostic plots, MCMC samples, and posterior distributions - are saved as files and db records. +nothing. Diagnostic plots, MCMC samples, and posterior +distributions are saved as files and db records. } \description{ Paramater Data Assimilation using MCMC diff --git a/web/workflow.R b/web/workflow.R index 0a433ecc866..6e4bae65e80 100644 --- a/web/workflow.R +++ b/web/workflow.R @@ -141,11 +141,13 @@ run.sensitivity.analysis() status.end() # Run parameter data assimilation -status.start("PDA") -settings$assim.batch <- pda.mcmc(settings) -saveXML(listToXml(settings, "pecan"), file=file.path(settings$outdir, 'pecan.pda.xml')) -status.end() - +if(('assim.batch' %in% names(settings))) { + status.start("PDA") + settings$assim.batch <- pda.mcmc(settings) + saveXML(listToXml(settings, "pecan"), file=file.path(settings$outdir, 'pecan.pda.xml')) + status.end() +} + # all done status.start("FINISHED") db.query(paste("UPDATE workflows SET finished_at=NOW() WHERE id=", settings$workflow$id, "AND finished_at IS NULL"), params=settings$database$bety)