[Pomp-commits] r511 - pkg/man
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Mon Jun 6 16:19:09 CEST 2011
Author: kingaa
Date: 2011-06-06 16:19:09 +0200 (Mon, 06 Jun 2011)
New Revision: 511
Modified:
pkg/man/bsplines.Rd
pkg/man/dacca.Rd
pkg/man/eulermultinom.Rd
pkg/man/gompertz.Rd
pkg/man/nlf.Rd
pkg/man/plugins.Rd
pkg/man/pomp-methods.Rd
pkg/man/pomp.Rd
pkg/man/ricker.Rd
Log:
- documentation improvements
Modified: pkg/man/bsplines.Rd
===================================================================
--- pkg/man/bsplines.Rd 2011-06-05 15:40:21 UTC (rev 510)
+++ pkg/man/bsplines.Rd 2011-06-06 14:19:09 UTC (rev 511)
@@ -19,7 +19,7 @@
\item{names}{
optional; the names to be given to the basis functions.
These will be the column-names of the matrix returned.
- If the names are specified as a format string (e.g., "basis%d"), \code{\link{sprintf}} will be used to generate the names from the column number.
+ If the names are specified as a format string (e.g., "basis\%d"), \code{\link{sprintf}} will be used to generate the names from the column number.
If a single non-format string is specified, the names will be generated by \code{\link{paste}}-ing \code{name} to the column number.
One can also specify each column name explicitly by giving a length-\code{nbasis} string vector.
By default, no column-names are given.
Modified: pkg/man/dacca.Rd
===================================================================
--- pkg/man/dacca.Rd 2011-06-05 15:40:21 UTC (rev 510)
+++ pkg/man/dacca.Rd 2011-06-06 14:19:09 UTC (rev 511)
@@ -12,16 +12,24 @@
}
\usage{
data(dacca)
+dacca.transform(params,dir=c("forward","inverse"))
}
\details{
\code{dacca} is a \code{pomp} object containing the model, data, and MLE parameters.
\code{dacca.transform} is a function that transforms the parameters.
+ If \code{params} is a matrix or vector of parameters on the natural scale for this model, \code{dacca.transform(params,dir="forward")} is the corresponding matrix or vector of parameters on the scale that they are used internally.
+ If \code{params} is a matrix or vector of parameters on the internal scale for this model, \code{dacca.transform(params,dir="inverse")} is the corresponding matrix or vector of parameters on the natural scale.
+ Parameters that naturally range over the positive reals are log-transformed by \code{dacca.transform};
+ parameters that range over the unit interval are logit-transformed;
+ parameters that are naturally unbounded or take integer values are not transformed.
}
\examples{
data(dacca)
plot(dacca)
-theta <- dacca.transform(coef(dacca),dir="inverse") #MLEs
+#MLEs on the natural scale
+theta <- dacca.transform(coef(dacca),dir="inverse")
plot(simulate(dacca))
+# now change 'eps' and simulate again
theta["eps"] <- 1
plot(simulate(dacca,params=dacca.transform(theta,dir="forward")))
}
Modified: pkg/man/eulermultinom.Rd
===================================================================
--- pkg/man/eulermultinom.Rd 2011-06-05 15:40:21 UTC (rev 510)
+++ pkg/man/eulermultinom.Rd 2011-06-06 14:19:09 UTC (rev 511)
@@ -1,8 +1,8 @@
-\name{Euler-multinomial models}
+\name{eulermultinom}
\alias{eulermultinom}
\alias{reulermultinom}
\alias{deulermultinom}
-\title{Euler-multinomial models}
+\title{Euler-multinomial death process}
\description{
Density and random-deviate generation for the Euler-multinomial death process with parameters \code{size}, \code{rate}, and \code{dt}.
}
@@ -15,10 +15,28 @@
\item{size}{scalar integer; number of individuals at risk.}
\item{rate}{numeric vector of hazard rates.}
\item{dt}{numeric scalar; duration of Euler step.}
- \item{x}{Matrix or vector containing number of individuals that have succumbed to each death process.}
+ \item{x}{matrix or vector containing number of individuals that have succumbed to each death process.}
\item{log}{logical; if TRUE, return logarithm(s) of probabilities.}
}
\details{
+ If \eqn{N} individuals face constant hazards of death in \eqn{k} ways at rates \eqn{r_1, r_2, \dots, r_k}, then in an interval of duration \eqn{\Delta t}, the number of individuals remaining alive and dying in each way is multinomially distributed:
+ \deqn{(N-\sum_{i=1}^k \Delta n_i, \Delta n_1, \dots, \Delta n_k) \sim \mathrm{multinomial}(N;p_0,p_1,\dots,p_k),}
+ where \eqn{\Delta n_i} is the number of individuals dying in way \eqn{i} over the interval, the probability of remaining alive is \eqn{p_0=\exp(-\sum_i r_i \Delta t)}, and the probability of dying in way \eqn{j} is
+ \deqn{p_j=\frac{r_j}{\sum_i r_i} (1-\exp(-\sum_i r_i \Delta t)).}
+ In this case, we can say that
+ \deqn{(\Delta n_1, \dots, \Delta n_k) \sim \mathrm{eulermultinom}(N,r,\Delta t),}
+ where \eqn{r=(r_1,\dots,r_k)}.
+ Draw \eqn{m} random samples from this distribution by doing
+
+ \code{reulermultinom(n=m,size=N,rate=r,dt=dt)},
+
+ where \code{r} is the vector of rates.
+ Evaluate the probability that \eqn{x_1,\dots,x_k} are the numbers of individuals who have died in each of the \eqn{k} ways over the interval \eqn{\Delta t=}\code{dt}, by doing
+
+ \code{deulermultinom(x=x,size=N,rate=r,dt=dt)},
+
+ where \code{x} is a length \eqn{k} vector and \code{x[i]=}\eqn{x_i}.
+
Direct access to the underlying C routines is available: see the header file \dQuote{pomp.h}, included with the package.
}
\value{
Modified: pkg/man/gompertz.Rd
===================================================================
--- pkg/man/gompertz.Rd 2011-06-05 15:40:21 UTC (rev 510)
+++ pkg/man/gompertz.Rd 2011-06-06 14:19:09 UTC (rev 511)
@@ -7,8 +7,8 @@
}
\usage{data(gompertz)}
\details{
- The state process is \eqn{X_{t+1} = K^(1-R) X_{t}^R eps_{t}}, where the \eqn{eps_t} are i.i.d. lognormal random deviates with variance \eqn{sigma^2}.
- The observed variables \eqn{Y_t} are distributed as \eqn{normal(X_t,tau)}.
+ The state process is \eqn{X_{t+1} = K^{(1-R)} X_{t}^R \varepsilon_{t}}, where the \eqn{\varepsilon_t} are i.i.d. lognormal random deviates with variance \eqn{\sigma^2}.
+ The observed variables \eqn{Y_t} are distributed as \eqn{\mathrm{normal}(X_t,\tau)}.
}
\examples{
data(gompertz)
Modified: pkg/man/nlf.Rd
===================================================================
--- pkg/man/nlf.Rd 2011-06-05 15:40:21 UTC (rev 510)
+++ pkg/man/nlf.Rd 2011-06-06 14:19:09 UTC (rev 511)
@@ -7,8 +7,10 @@
}
\usage{
nlf(object, start, est, lags, period = NA, tensor = FALSE,
- nconverge=1000, nasymp=1000, seed = 1066, transform = function (x) x,
- nrbf = 4, method = "subplex", skip.se = FALSE, verbose = FALSE, gr = NULL,
+ nconverge=1000, nasymp=1000, seed = 1066,
+ transform = function (x) x,
+ nrbf = 4, method = "subplex", skip.se = FALSE,
+ verbose = FALSE, gr = NULL,
bootstrap=FALSE, bootsamp = NULL,
lql.frac = 0.1, se.par.frac = 0.1, eval.only = FALSE, \dots)
}
Modified: pkg/man/plugins.Rd
===================================================================
--- pkg/man/plugins.Rd 2011-06-05 15:40:21 UTC (rev 510)
+++ pkg/man/plugins.Rd 2011-06-06 14:19:09 UTC (rev 511)
@@ -116,7 +116,8 @@
\author{Aaron A. King \email{kingaa at umich dot edu}}
\seealso{\code{\link{eulermultinom}}, \code{\link{pomp}}}
\examples{
-## example showing how to use these functions are provided in the vignette "intro_to_pomp"
+## examples showing how to use these functions
+## are provided in the vignette "intro_to_pomp"
\dontrun{
vignette("intro_to_pomp")
}
Modified: pkg/man/pomp-methods.Rd
===================================================================
--- pkg/man/pomp-methods.Rd 2011-06-05 15:40:21 UTC (rev 510)
+++ pkg/man/pomp-methods.Rd 2011-06-06 14:19:09 UTC (rev 511)
@@ -218,7 +218,7 @@
\code{\link{rmeasure}},
\code{\link{dmeasure}},
\code{\link{init.state}},
- \link{simulate-pomp}
+ \code{\link[=simulate-pomp]{simulate}}
}
\keyword{models}
\keyword{ts}
Modified: pkg/man/pomp.Rd
===================================================================
--- pkg/man/pomp.Rd 2011-06-05 15:40:21 UTC (rev 510)
+++ pkg/man/pomp.Rd 2011-06-06 14:19:09 UTC (rev 511)
@@ -14,19 +14,22 @@
}
\usage{
\S4method{pomp}{data.frame}(data, times, t0, \dots, rprocess, dprocess, rmeasure, dmeasure,
- measurement.model, skeleton = NULL, skeleton.type = c("map","vectorfield"),
+ measurement.model,
+ skeleton = NULL, skeleton.type = c("map","vectorfield"),
skeleton.map = NULL, skeleton.vectorfield = NULL,
initializer, covar, tcovar,
obsnames, statenames, paramnames, covarnames,
PACKAGE)
\S4method{pomp}{numeric}(data, times, t0, \dots, rprocess, dprocess, rmeasure, dmeasure,
- measurement.model, skeleton = NULL, skeleton.type = c("map","vectorfield"),
+ measurement.model,
+ skeleton = NULL, skeleton.type = c("map","vectorfield"),
skeleton.map = NULL, skeleton.vectorfield = NULL,
initializer, covar, tcovar,
obsnames, statenames, paramnames, covarnames,
PACKAGE)
\S4method{pomp}{matrix}(data, times, t0, \dots, rprocess, dprocess, rmeasure, dmeasure,
- measurement.model, skeleton = NULL, skeleton.type = c("map","vectorfield"),
+ measurement.model,
+ skeleton = NULL, skeleton.type = c("map","vectorfield"),
skeleton.map = NULL, skeleton.vectorfield = NULL,
initializer, covar, tcovar,
obsnames, statenames, paramnames, covarnames,
@@ -272,7 +275,8 @@
}
}
\examples{
-## For examples, see the vignettes, the data()-loadable example \code{pomp} objects, and the provided example files.
+## For examples, see the vignettes, the data()-loadable
+## example \code{pomp} objects, and the provided example files.
\dontrun{
vignette("intro_to_pomp")
vignette("advanced_topics_in_pomp")
Modified: pkg/man/ricker.Rd
===================================================================
--- pkg/man/ricker.Rd 2011-06-05 15:40:21 UTC (rev 510)
+++ pkg/man/ricker.Rd 2011-06-06 14:19:09 UTC (rev 511)
@@ -7,8 +7,8 @@
}
\usage{data(ricker)}
\details{
- The state process is \eqn{N_{t+1} = r N_{t} exp(-N_{t}+e_{t})}, where the \eqn{e_t} are i.i.d. normal random deviates with variance \eqn{sigma^2}.
- The observed variables \eqn{y_t} are distributed as \eqn{Poisson(\phi N_t)}.
+ The state process is \eqn{N_{t+1} = r N_{t} exp(-N_{t}+e_{t})}, where the \eqn{e_t} are i.i.d. normal random deviates with variance \eqn{\sigma^2}.
+ The observed variables \eqn{y_t} are distributed as \eqn{\mathrm{Poisson}(\phi N_t)}.
}
\examples{
data(ricker)
More information about the pomp-commits
mailing list