Skip to content

Commit

Permalink
include DOI for references
Browse files Browse the repository at this point in the history
  • Loading branch information
kingaa committed Jul 2, 2024
1 parent 0718fbb commit 0002251
Show file tree
Hide file tree
Showing 7 changed files with 55 additions and 49 deletions.
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
^www
^yaml
^Makefile
^TAGS
^rules.mk
^tests/Makefile
^tests/(.+?)\.png$
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ rchk\.out
*.gcno
*.pdf
*.sif
/TAGS
/scripts
check
lib
Expand Down
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Package: pomp
Type: Package
Title: Statistical Inference for Partially Observed Markov Processes
Version: 5.10.0.0
Date: 2024-07-01
Version: 5.10.0.1
Date: 2024-07-02
Authors@R: c(person(given=c("Aaron","A."),family="King",role=c("aut","cre"),email="[email protected]",comment=c(ORCID="0000-0001-6159-3207")),
person(given=c("Edward","L."),family="Ionides",role="aut",comment=c(ORCID="0000-0002-4190-0174")) ,
person(given="Carles",family="Bretó",role="aut",comment=c(ORCID="0000-0003-4695-4902")),
Expand Down
9 changes: 4 additions & 5 deletions R/kalman.R
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
##' @inheritParams pfilter
##' @inheritParams pomp
##' @param Np integer; the number of particles to use, i.e., the size of the ensemble.
##'
##' @return
##' An object of class \sQuote{kalmand_pomp}.
##' @references
Expand Down Expand Up @@ -186,7 +185,7 @@ enkf_internal <- function (object, Np, ..., verbose) {
Np <- as.integer(Np)
if (length(Np)>1 || !is.finite(Np) || isTRUE(Np<=0))
pStop_(sQuote("Np")," should be a single positive integer.")

params <- coef(object)

t <- time(object)
Expand All @@ -213,7 +212,7 @@ enkf_internal <- function (object, Np, ..., verbose) {
## advance ensemble according to state process
X <- rprocess(object,x0=X,t0=tt[k],times=tt[k+1],params=params,.gnsi=first)
rn <- rownames(X)

predMeans[,k] <- pm <- rowMeans(X) # prediction mean
Y <- emeasure(object,x=X,times=tt[k+1],params=params,.gnsi=first)
ym <- rowMeans(Y) # forecast mean
Expand All @@ -236,7 +235,7 @@ enkf_internal <- function (object, Np, ..., verbose) {

dn <- dim(R)[c(1L,2L)]
dim(R) <- dn

sqrtR <- tryCatch(
t(chol(R)), ## t(sqrtR)%*%sqrtR == R
error = function (e) {
Expand Down Expand Up @@ -380,7 +379,7 @@ eakf_internal <- function (object, Np, ..., verbose) {
Np <- as.integer(Np)
if (length(Np)>1 || !is.finite(Np) || isTRUE(Np<=0))
pStop_(sQuote("Np")," should be a single positive integer.")

params <- coef(object)

t <- time(object)
Expand Down
12 changes: 6 additions & 6 deletions R/probe_match.R
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,13 @@
##' @family summary statistic-based methods
##' @family estimation methods
##' @family methods based on maximization
##' @seealso \code{\link[stats]{optim}} \code{\link[subplex]{subplex}} \code{\link[nloptr]{nloptr}}
##' @references
##'
##' \Kendall1999
##'
##' \Wood2010
##'
##' @seealso \code{\link[stats]{optim}} \code{\link[subplex]{subplex}} \code{\link[nloptr]{nloptr}}
##' @param est character vector; the names of parameters to be estimated.
##' @param fail.value optional numeric scalar;
##' if non-\code{NA}, this value is substituted for non-finite values of the objective function.
Expand All @@ -26,22 +31,18 @@
##' When fitting, it is often best to fix the seed of the random-number generator (RNG).
##' This is accomplished by setting \code{seed} to an integer.
##' By default, \code{seed = NULL}, which does not alter the RNG state.
##'
##' @inheritParams probe
##' @inheritParams pomp
##'
##' @return
##' \code{probe_objfun} constructs a stateful objective function for probe matching.
##' Specifically, \code{probe_objfun} returns an object of class \sQuote{probe_match_objfun}, which is a function suitable for use in an \code{\link[stats]{optim}}-like optimizer.
##' In particular, this function takes a single numeric-vector argument that is assumed to contain the parameters named in \code{est}, in that order.
##' When called, it will return the negative synthetic log likelihood for the probes specified.
##' It is a stateful function:
##' Each time it is called, it will remember the values of the parameters and its estimate of the synthetic likelihood.
##'
##' @inheritSection pomp Note for Windows users
##' @inheritSection objfun Important Note
##' @inheritSection objfun Warning! Objective functions based on C snippets
##'
##' @example examples/probe_match.R
##'
NULL
Expand Down Expand Up @@ -293,4 +294,3 @@ setMethod(
plot(as(x,"probed_pomp"),...)
}
)

Loading

0 comments on commit 0002251

Please sign in to comment.