[Pomp-commits] r1021 - pkg/pompExamples/vignettes

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Wed Dec 17 20:12:10 CET 2014


Author: kingaa
Date: 2014-12-17 20:12:10 +0100 (Wed, 17 Dec 2014)
New Revision: 1021

Removed:
   pkg/pompExamples/vignettes/Makefile
   pkg/pompExamples/vignettes/budmoth-model-slices.rda
   pkg/pompExamples/vignettes/budmoth-model-true-loglik.rda
   pkg/pompExamples/vignettes/budmoth-model.Rnw
   pkg/pompExamples/vignettes/budmoth-model.pdf
   pkg/pompExamples/vignettes/fullnat.bst
   pkg/pompExamples/vignettes/pertussis-model-true-loglik.rda
   pkg/pompExamples/vignettes/pertussis-model.Rnw
   pkg/pompExamples/vignettes/pertussis-model.pdf
   pkg/pompExamples/vignettes/pomp.bib
Log:
- remove all vignettes

Deleted: pkg/pompExamples/vignettes/Makefile
===================================================================
--- pkg/pompExamples/vignettes/Makefile	2014-12-17 19:12:06 UTC (rev 1020)
+++ pkg/pompExamples/vignettes/Makefile	2014-12-17 19:12:10 UTC (rev 1021)
@@ -1,25 +0,0 @@
-RSCRIPT = $(R_HOME)/bin/Rscript --vanilla
-REXE = $(R_HOME)/bin/R --vanilla
-LATEX = latex
-BIBTEX = bibtex
-PDFLATEX = pdflatex
-
-default: vignettes clean
-
-vignettes: budmoth-model.pdf pertussis-model.pdf
-
-%.tex: %.Rnw
-	$(REXE) CMD Sweave $*
-
-%.pdf: %.tex
-	$(PDFLATEX) $*
-	-$(BIBTEX) $*
-	$(PDFLATEX) $*
-	$(PDFLATEX) $*
-	$(RSCRIPT) -e "tools::compactPDF(\"$*.pdf\")";
-
-clean:
-	$(RM) *.tex *.log *.aux *.blg *.bbl *.out *.Rout *.toc *.lof *.lot 
-	$(RM) Rplots.pdf
-	$(RM) budmoth-model-*.pdf pertussis-model-*.pdf 
-	$(RM) budmoth-model-*.png pertussis-model-*.png

Deleted: pkg/pompExamples/vignettes/budmoth-model-slices.rda
===================================================================
(Binary files differ)

Deleted: pkg/pompExamples/vignettes/budmoth-model-true-loglik.rda
===================================================================
(Binary files differ)

Deleted: pkg/pompExamples/vignettes/budmoth-model.Rnw
===================================================================
--- pkg/pompExamples/vignettes/budmoth-model.Rnw	2014-12-17 19:12:06 UTC (rev 1020)
+++ pkg/pompExamples/vignettes/budmoth-model.Rnw	2014-12-17 19:12:10 UTC (rev 1021)
@@ -1,518 +0,0 @@
-\documentclass[10pt,reqno,final]{amsart}
-%\VignetteIndexEntry{The larch budmoth example}
-\usepackage{times}
-\pagestyle{plain}
-\usepackage[utf8]{inputenc}
-\usepackage{natbib}
-\usepackage[pdftex]{graphicx}
-\usepackage{paralist}
-\usepackage[nogin]{Sweave}
-\bibliographystyle{ecology}
-
-\setlength{\textwidth}{6.25in}
-\setlength{\textheight}{8.75in}
-\setlength{\evensidemargin}{0in}
-\setlength{\oddsidemargin}{0in}
-\setlength{\topmargin}{-.35in}
-\setlength{\parskip}{.1in}  
-\setlength{\parindent}{0.0in}  
-\setcounter{secnumdepth}{1}
-\setcounter{tocdepth}{1}
-
-\newcommand\code[1]{\texttt{#1}}
-\newcommand{\R}{\textsf{R}}
-\newcommand\logit{{\mathrm{logit}}}
-\newcommand\expit{{\mathrm{expit}}}
-
-\SweaveOpts{echo=T,results=verbatim,print=F,eps=F,pdf=F,png=T,keep.source=T,split=F,prefix=T,prefix.string=budmoth-model,resolution=150}
-
-\title{Larch Budmoth State-Space Model}
-\author{AAK, ELI, SPE, KBN}
-\date{\today}
-
-\begin{document}
-
-\maketitle
-
-<<options,echo=F,results=hide>>=
-require(pompExamples)
-require(xtable)
-glop <- options(keep.source=TRUE,width=60,continue=" ",prompt=" ")
-options(
-        device='pdf',
-        SweaveHooks=list(
-          clean=function()rm(list=ls(envir=.GlobalEnv),envir=.GlobalEnv)
-          )
-        )
-pdf.options(useDingbats=FALSE)
-set.seed(5384959)
-@ 
-
-\begin{itemize}
-\item Three state variables, 
-  $Q_t$ (measure of food quality on $[0,1]$), 
-  $N_t$ (budmoth density) and 
-  $S_t$ (fraction of budmoth larvae infected with parasitoids).
-
-\item Three observations, $\hat Q_t$ (needle length), $\hat N_t$ and $\hat S_t$.
-\end{itemize}
-
-\section{State process}
-
-Uncorrelated random effects, for $t=1,\ldots,T$:
-\begin{eqnarray}
-\alpha_t &\sim& \mathrm{LogitNormal}(\logit(\alpha),\sigma_{\alpha}^2)\\
-\lambda_t &\sim& \mathrm{Gamma}(\lambda,\sigma_{\lambda}^2)\\
-a_t &\sim& \mathrm{LogNormal}(\log(a),\sigma_{a}^2)
-\end{eqnarray}
-Note: $X$ is $\mathrm{LogitNormal}(\mu,\sigma^2)$ if $\logit(X)$ is $\mathrm{Normal}(\mu,\sigma^2)$. 
-
-The inverse of $\logit$ is $\expit$. 
-R functions \texttt{logit}, \texttt{expit}, \texttt{rlogitnorm}, \texttt{dlogitnorm} are part of \texttt{pompExamples}.
-
-The state process, for $t=1,\ldots,T$:
-\begin{eqnarray}
-Q_{t} &=& (1-\alpha_{t})\frac{\gamma}{\gamma+N_{t-1}} +\alpha_{t}Q_{t-1} \\
-N_{t} &=& \lambda_t N_{t-1} (1-S_{t-1})\exp\big\{-gN_{t-1}-\delta(1-Q_{t-1})\big\} \\
-S_{t} &=&  1-\exp
-  \left(\frac{-a_tS_{t-1}N_{t-1}}{1+a_twS_{t-1}N_{t-1}} \right) \label{eq6}
-\end{eqnarray}
-
-\section{Measurement process}
-For $t=1,\ldots,T$:
-\begin{eqnarray}
-\hat Q_t &\sim& \mathrm{LogNormal}(\log(\beta_0+\beta_1Q_t),\sigma_Q^2) \label{eq7}\\
-\hat N_t  &\sim& \mathrm{LogNormal}(\log(N_t),\sigma_N^2) \\
-\hat S_t &\sim&  \mathrm{LogitNormal}(\logit(uS_t),\sigma_S^2)\label{eq9}
-\end{eqnarray}
-
-\section{Identifiability and constraints}
-
-One may wish to set $\beta_0=0$. 
-The logic is as follows: the steady state value of $Q_t$ is $\bar Q=\gamma/(\gamma+\bar N)$. 
-If $Q_t$ is in practice close to this value then $\bar Q$ identifies the mean of $\hat Q_t$ in (\ref{eq7}), leaving only the scale parameter $\beta_1$ to be determined. 
-Thus, the combination of $\gamma$, $\beta_0$ and $\beta_1$ is only weakly identifiable when $Q_t$ varies over only a fraction of its full range of $[0,1]$.
-
-\section{The budmoth example implemented}
-
-This model is implemented in the package and can be loaded with the command
-<<>>=
-
-require(pompExamples)
-
-budmoth.sim()
-bmPomps <- list(
-                tri=budmoth.sim(tri),
-                food=budmoth.sim(food),
-                para1=budmoth.sim(para1),
-                para2=budmoth.sim(para2)
-                )
-
-@ 
-The object thereby loaded contains a named, length-\Sexpr{length(budmoth.sim)} list of pomp objects
-<<>>=
-names(bmPomps)
-@ 
-There are three parameter regimes (``food'', ``para'', and ``tri'' representing a food-quality-dominated, a parasitoid-dominated, and true tritrophic dynamics, respectively).
-In total, there are \Sexpr{length(bmPomps)} imulated data sets of length \Sexpr{diff(range(time(bmPomps[[1]])))+1} years.
-<<echo=F>>=
-for (q in names(bmPomps)) {
-  time(bmPomps[[q]]) <- 1:60
-}
-@ 
-The process model is implemented using the \code{euler.simulate} plugin with step function \verb+budmoth_map+ defined in \code{src/budmoth.c} in the package source.
-The log likelihood of any state transition is given by the native routine \verb+budmoth_density+.
-The measurement model is simulated using \verb+budmoth_rmeasure+
-and the likelihood is computed via \verb+budmoth_dmeasure+.
-Finally, the state process is initialized by 
-<<echo=F>>=
-bmPomps[[1]]@initializer
-@ 
-The parameters at which the simulated data are generated can be extracted via
-<<true-params>>=
-true.pars <- sapply(bmPomps[c("food","para1","para2","tri")],coef)
-@ 
-and are displayed in Table~\ref{tab:sim-params}.
-
-<<true-params-table,echo=F,results=tex>>=
-params <- as.data.frame(true.pars)
-params$name <- rownames(params)
-params$math <- ""
-params[c("alpha","sig.alpha","gam","lambda","sig.lambda",
-         "g","delta","a","w","sig.a","beta0","beta1","u",
-         "sigQobs","sigNobs","sigSobs","Q.0","N.0","S.0"),"math"] <- c("$\\alpha$","$\\sigma_{\\alpha}$","$\\gamma$",
-                                                                       "$\\lambda$","$\\sigma_{\\lambda}$","$g$","$\\delta$",
-                                                                       "$a$","$w$","$\\sigma_{a}$",
-                                                                       "$\\beta_{0}$","$\\beta_{1}$",
-                                                                       "$u$","$\\sigma_{Q}$","$\\sigma_{N}$","$\\sigma_{S}$",
-                                                                       "$Q_{0}$","$N_{0}$","$S_{0}$")
-params <- params[c("math","name","food","para1","para2","tri")]
-names(params) <- c("parameter","R name","food","para1","para2","tri")
-print(
-      xtable(
-             params,
-             caption="Parameters of the larch budmoth model, and the values corresponding to the simulated data.",
-             label="tab:sim-params"
-             ),
-      type='latex',
-      floating=TRUE,
-      caption.placement="top",
-      include.rownames=FALSE,
-      hline.after=c(-1,-1,0,nrow(params)),
-      sanitize.text.function=identity
-      )
-@ 
-
-\setkeys{Gin}{width=0.8\textwidth}
-
-\begin{figure}
-<<data-plot,fig=T,height=6,width=8,pdf=T,png=F,echo=F>>=
-require(pompExamples)
-require(plyr)
-require(reshape2)
-require(ggplot2)
-bmPomps <- list(
-                tri=budmoth.sim(tri),
-                food=budmoth.sim(food),
-                para1=budmoth.sim(para1),
-                para2=budmoth.sim(para2)
-                )
-x <- ldply(bmPomps,as.data.frame)
-x <- rename(x,c(.id="dataset"))
-x <- melt(x,id.var=c("dataset","time"))
-x <- subset(x,variable%in%c("Qobs","Nobs","Sobs"))
-pl <- ggplot(data=x,mapping=aes(x=time,y=value))+
-  geom_line()+facet_grid(variable~dataset,scale="free")
-print(pl)
-@   
-  \caption{Plot of the simulated budmoth data.}
-\end{figure}
-
-We can get a benchmark for likelihood-based fitting methods by computing the true likelihood at the true parameter values.
-To do this, we run the \code{pfilter} particle filtering code.
-<<true-loglik-calc,echo=F,eval=F>>=
-require(Rmpi)
-require(mpifarm)
-require(pompExamples)
-
-bmPomps <- list(
-                tri=budmoth.sim(tri),
-                food=budmoth.sim(food),
-                para1=budmoth.sim(para1),
-                para2=budmoth.sim(para2)
-                )
-
-ncpus <- length(bmPomps)
-
-nrep <- 10  ### number of particle filters to run
-Np <- 10000 ### number of particles
-
-set.seed(5384959)
-
-mpi.spawn.Rslaves(nslaves=ncpus)
-
-mpi.farmer(
-           chunk=5,
-           seeds=as.integer(floor(runif(n=nrep,1,2^31))),
-           jobs={
-             require(plyr)
-             dlply(
-                   expand.grid(
-                               seed=seeds,
-                               dataset=names(bmPomps)
-                               ),
-                   ~dataset+seed
-                   )
-           },
-           common=list(
-             pomps=bmPomps,
-             Np=Np
-             ),
-           main={
-             require(pompExamples)
-             save.seed <- .Random.seed
-             set.seed(seed)
-             tic <- Sys.time()
-             pf <- try(pfilter(pomps[[dataset]],Np=Np,max.fail=100,warn=FALSE))
-             if (inherits(pf,"try-error")) {
-               loglik <- NA
-               nfail <- NA
-             } else {
-               loglik <- logLik(pf)
-               nfail <- pf$nfail
-             }
-             toc <- Sys.time()
-             .Random.seed <<- save.seed
-             data.frame(
-                        seed=seed,
-                        dataset=dataset,
-                        loglik=loglik,
-                        nfail=nfail,
-                        etime=toc-tic
-                        )
-           },
-           post={
-             require(plyr)
-             ldply(results)
-           }
-           ) -> results
-
-mpi.close.Rslaves()
-
-if (any(with(results,nfail!=0)))
-  warning("filtering failures occurred!")
-
-etime <- sum(results$etime)
-
-ll.est <- function (x) {
-  bl <- mean(x$loglik)
-  loglik <- bl+log(mean(exp(x$loglik-bl)))
-  se <- sd(exp(x$loglik-bl))/exp(loglik-bl)
-  data.frame(loglik=loglik,se=se)
-}
-
-loglik.truth <- ddply(results,~dataset,ll.est)
-
-save(loglik.truth,etime,Np,nrep,ncpus,file=binary.file,compress="xz")
-@ 
-<<true-loglik-eval,echo=F,results=hide>>=
-binary.file <- "budmoth-model-true-loglik.rda"
-if (file.exists(binary.file)) {
-  load(binary.file)
-} else {
-<<true-loglik-calc>>
-}
-@ 
-Table~\ref{tab:true-loglik} shows these likelihoods.
-
-<<true-loglik,results=tex,echo=F>>=
-nest <- 6
-loglik.truth[["5\\%"]] <- loglik.truth$loglik+qchisq(p=0.05,df=nest)/2
-print(
-      xtable(
-             loglik.truth,
-             caption=paste(
-               "Estimated log likelihood at the true parameters for the simulated budmoth data. ",
-               "To obtain these,",nrep,"particle filtering runs, each with",Np,"particles, were used. ",
-               "The column labeled",dQuote("se"),"gives the standard error of the Monte Carlo likelihood calculation. ",
-               "The computation took ",signif(etime,2),"~CPU~",units(etime),"on inexpensive processors. ",
-               "The last column shows the likelihood we would expect to achieve at the MLE 95\\% of the time when estimating",
-               nest,"parameters.",
-               sep=" "
-               ),
-             label="tab:true-loglik",
-             digits=c(0,0,1,2,1)
-             ),
-      type="latex",
-      floating=TRUE,
-      caption.placement="top",
-      include.rownames=FALSE,
-      sanitize.text.function=identity,
-      hline.after=c(-1,-1,0,nrow(loglik.truth))
-      )
-@ 
-
-To get some sense of the shape of the likelihood surface, we can construct slices through each of the true parameter points.
-These likelihood slices are shown in Fig.~\ref{fig:slices}.
-<<slices-calc,eval=F,echo=F>>=
-require(pompExamples)
-require(Rmpi)
-require(mpifarm)
-
-nrep <- 3  ### number of particle filters to run per parameter point
-Np <- 1000 ### number of particles per filter
-slice.length <- 100          ### number of points per slice
-
-bmPomps <- list(
-                tri=budmoth.sim(tri),
-                food=budmoth.sim(food),
-                para1=budmoth.sim(para1),
-                para2=budmoth.sim(para2)
-                )
-
-true.pars <- sapply(bmPomps,coef)
-estnames <- c("gam","lambda","g","delta","a","w")
-par.range <- t(apply(true.pars[estnames,],1,function(x)c(0.5*min(x),1.5*max(x))))
-  
-ncpus <- as.integer(Sys.getenv("PBS_NP"))
-
-slices <- lapply(
-                 bmPomps,
-                 function (po) {
-                   center <- coef(po)
-                   ranges <- lapply(
-                                    estnames,
-                                    function(n) seq(
-                                                    from=par.range[n,1],
-                                                    to=par.range[n,2],
-                                                    length=slice.length
-                                                    )
-                                    )
-                   names(ranges) <- estnames
-                   do.call(sliceDesign,c(list(center=center),ranges))
-                 }
-                 )
-
-require(plyr)
-slices <- ldply(slices)
-rename(slices,c(.id="dataset")) -> slices
-
-set.seed(5384959)
-
-mpi.spawn.Rslaves(nslaves=ncpus)
-
-mpi.farmer(
-           chunk=20,
-           checkpoint=1000,
-           checkpoint.file=file.path(getwd(),"budmoth-slices-ckpt.rda"),
-           seeds=as.integer(floor(runif(n=nrep*nrow(slices),1,2^31))),
-           jobs={
-             joblist <- vector(mode="list",length=nrep*nrow(slices))
-             s <- 0
-             for (j in seq_len(nrow(slices))) {
-               ds <- slices$dataset[j]
-               sl <- slices$slice[j]
-               paramnames <- names(coef(bmPomps[[ds]]))
-               for (k in seq_len(nrep)) {
-                 s <- s+1
-                 joblist[[s]] <- list(
-                                      params=unlist(slices[j,paramnames]),
-                                      seed=seeds[s],
-                                      dataset=ds,
-                                      slice=sl
-                                      )
-               }
-             }
-             joblist
-           },
-           common=list(
-             pomps=bmPomps,
-             Np=Np,
-             estnames=estnames
-             ),
-           main={
-             require(pompExamples)
-             po <- pomps[[dataset]]
-             save.seed <- .Random.seed
-             set.seed(seed)
-             tic <- Sys.time()
-             pf <- try(pfilter(po,params=params,Np=Np,max.fail=100,warn=FALSE))
-             if (inherits(pf,"try-error")) {
-               loglik <- NA
-               nfail <- NA
-               cond.loglik <- pf$cond.loglik
-             } else {
-               loglik <- logLik(pf)
-               nfail <- pf$nfail
-               cond.loglik <- pf$cond.loglik
-             }
-             toc <- Sys.time()
-             .Random.seed <<- save.seed
-             list(
-                  params=params,
-                  slice=slice,
-                  dataset=dataset,
-                  loglik=loglik,
-                  nfail=nfail,
-                  cond.loglik=cond.loglik,
-                  etime=toc-tic
-                  )
-           },
-           post={
-             require(plyr)
-             ldply(
-                   results,
-                   function(x)data.frame(
-                                         dataset=x$dataset,
-                                         slice=x$slice,
-                                         as.list(x$params),
-                                         loglik=x$loglik,
-                                         nfail=x$nfail,
-                                         etime=x$etime
-                                         )
-                   )
-           }
-           ) -> slices
-
-mpi.close.Rslaves()
-
-save(slices,file=binary.file,compress="xz")
-@ 
-<<slices-eval,echo=F>>=
-binary.file <- "budmoth-model-slices.rda"
-if (file.exists(binary.file)) {
-  load(binary.file)
-} else {
-<<slices-calc>>
-}
-@ 
-These calculations took \Sexpr{signif(etime,3)}~CPU~\Sexpr{units(etime)} on inexpensive processors.
-
-\setkeys{Gin}{width=0.95\textwidth}
-
-\begin{figure}
-<<slices-plot,fig=T,png=T,pdf=F,echo=F,height=7,width=7>>=
-require(ggplot2)
-require(plyr)
-require(reshape2)
-slices$.id <- NULL
-slices$etime <- NULL
-slices$nfail <- NULL
-x <- melt(slices,id.vars=c("dataset","slice","loglik"))
-x$slice <- factor(x$slice,levels=levels(x$variable))
-x <- subset(x,slice==variable)
-x <- ddply(x,~dataset+slice,subset,loglik>max(loglik)-50)
-pl <- ggplot(data=x,mapping=aes(x=value,y=loglik))+
-  geom_point()+facet_grid(dataset~slice,scale="free")+
-  geom_smooth(method="loess")
-print(pl)
-@ 
-  \caption{
-    Sliced likelihood plots.
-    \label{fig:slices}
-  }
-\end{figure}
-
-To simulate ignorance, we will assume that we are uncertain about the values of some of the parameters.
-In particular, we will suppose that we wish to estimate the parameters that distinguish the regimes.
-<<estnames,echo=F>>=
-estnames <- names(which(apply(true.pars,1,function(x)diff(range(x))>0)))
-par.range <- signif(
-                    t(
-                      apply(
-                            true.pars[estnames,],
-                            1,
-                            function(x)c(0.5*min(x),1.5*max(x))
-                            )
-                      ),
-                    digits=3
-                    )
-colnames(par.range) <- c("lower","upper")
-@ 
-We will assume a hypercube within which we are uniformly uncertain as to the parameter values.
-The upper and lower limits for each of the parameters we will estimate are given in Table~\ref{tab:par-range}.
-
-<<ignorance-table,results=tex,echo=F>>=
-print(
-      xtable(
-             par.range,
-             caption="Parameters to estimate, and limits of uncertainty.",
-             label="tab:par-range",
-             display=c("s","fg","fg"),
-             digits=c(0,3,3)
-             ),
-      type="latex",
-      floating=TRUE,
-      caption.placement="top",
-      include.rownames=TRUE,
-#      sanitize.text.function=identity,
-      hline.after=c(-1,-1,0,nrow(par.range))
-      )
-@ 
-
-\end{document}
-
-<<echo=F>>=
-options(glop)
-@ 
-

Deleted: pkg/pompExamples/vignettes/budmoth-model.pdf
===================================================================
(Binary files differ)

Deleted: pkg/pompExamples/vignettes/fullnat.bst
===================================================================
--- pkg/pompExamples/vignettes/fullnat.bst	2014-12-17 19:12:06 UTC (rev 1020)
+++ pkg/pompExamples/vignettes/fullnat.bst	2014-12-17 19:12:10 UTC (rev 1021)
@@ -1,1429 +0,0 @@
-%%
-%% This is file `fullnat.bst',
-%% generated with the docstrip utility.
-%%
-%% The original source files were:
-%%
-%% merlin.mbs  (with options: `ay,nat,vonx,nm-init,ed-au,keyxyr,yr-par,note-yr,vol-bf,vnum-x,num-xser,jnm-x,pub-date,pp,ed,abr,xedn,etal-it,nfss,')
-%% ----------------------------------------
-%% ***  ***
-%% 
-%% Copyright 1994-2004 Patrick W Daly
- % ===============================================================
- % IMPORTANT NOTICE:
- % This bibliographic style (bst) file has been generated from one or
- % more master bibliographic style (mbs) files, listed above.
- %
- % This generated file can be redistributed and/or modified under the terms
- % of the LaTeX Project Public License Distributed from CTAN
- % archives in directory macros/latex/base/lppl.txt; either
- % version 1 of the License, or any later version.
- % ===============================================================
- % Name and version information of the main mbs file:
- % \ProvidesFile{merlin.mbs}[2004/02/09 4.13 (PWD, AO, DPC)]
- %   For use with BibTeX version 0.99a or later
- %-------------------------------------------------------------------
- % This bibliography style file is intended for texts in ENGLISH
- % This is an author-year citation style bibliography. As such, it is
- % non-standard LaTeX, and requires a special package file to function properly.
- % Such a package is    natbib.sty   by Patrick W. Daly
- % The form of the \bibitem entries is
- %   \bibitem[Jones et al.(1990)]{key}...
- %   \bibitem[Jones et al.(1990)Jones, Baker, and Smith]{key}...
- % The essential feature is that the label (the part in brackets) consists
- % of the author names, as they should appear in the citation, with the year
- % in parentheses following. There must be no space before the opening
- % parenthesis!
- % With natbib v5.3, a full list of authors may also follow the year.
- % In natbib.sty, it is possible to define the type of enclosures that is
- % really wanted (brackets or parentheses), but in either case, there must
- % be parentheses in the label.
- % The \cite command functions as follows:
- %   \citet{key} ==>>                Jones et al. (1990)
- %   \citet*{key} ==>>               Jones, Baker, and Smith (1990)
- %   \citep{key} ==>>                (Jones et al., 1990)
- %   \citep*{key} ==>>               (Jones, Baker, and Smith, 1990)
- %   \citep[chap. 2]{key} ==>>       (Jones et al., 1990, chap. 2)
- %   \citep[e.g.][]{key} ==>>        (e.g. Jones et al., 1990)
- %   \citep[e.g.][p. 32]{key} ==>>   (e.g. Jones et al., p. 32)
- %   \citeauthor{key} ==>>           Jones et al.
- %   \citeauthor*{key} ==>>          Jones, Baker, and Smith
- %   \citeyear{key} ==>>             1990
- %---------------------------------------------------------------------
-
-ENTRY
-  { address
-    author
-    booktitle
-    chapter
-    edition
-    editor
-    eid
-    howpublished
-    institution
-    journal
-    key
-    month
-    note
-    number
-    organization
-    pages
-    publisher
-    school
-    series
-    title
-    type
-    volume
-    year
-  }
-  {}
-  { label extra.label sort.label short.list }
-INTEGERS { output.state before.all mid.sentence after.sentence after.block }
-FUNCTION {init.state.consts}
-{ #0 'before.all :=
-  #1 'mid.sentence :=
-  #2 'after.sentence :=
-  #3 'after.block :=
-}
-STRINGS { s t}
-FUNCTION {output.nonnull}
-{ 's :=
-  output.state mid.sentence =
-    { ", " * write$ }
-    { output.state after.block =
-        { add.period$ write$
-          newline$
-          "\newblock " write$
-        }
-        { output.state before.all =
-            'write$
-            { add.period$ " " * write$ }
-          if$
-        }
-      if$
-      mid.sentence 'output.state :=
-    }
-  if$
-  s
-}
-FUNCTION {output}
-{ duplicate$ empty$
-    'pop$
-    'output.nonnull
-  if$
-}
-FUNCTION {output.check}
-{ 't :=
-  duplicate$ empty$
-    { pop$ "empty " t * " in " * cite$ * warning$ }
-    'output.nonnull
-  if$
-}
-FUNCTION {fin.entry}
-{ add.period$
-  write$
-  newline$
-}
-
-FUNCTION {new.block}
-{ output.state before.all =
-    'skip$
-    { after.block 'output.state := }
-  if$
-}
-FUNCTION {new.sentence}
-{ output.state after.block =
-    'skip$
-    { output.state before.all =
-        'skip$
-        { after.sentence 'output.state := }
-      if$
-    }
-  if$
-}
-FUNCTION {add.blank}
-{  " " * before.all 'output.state :=
-}
-
-FUNCTION {date.block}
-{
-  new.block
-}
-
-FUNCTION {not}
-{   { #0 }
-    { #1 }
-  if$
-}
-FUNCTION {and}
-{   'skip$
-    { pop$ #0 }
-  if$
-}
-FUNCTION {or}
-{   { pop$ #1 }
-    'skip$
-  if$
-}
-FUNCTION {new.block.checkb}
-{ empty$
-  swap$ empty$
-  and
-    'skip$
-    'new.block
-  if$
-}
-FUNCTION {field.or.null}
-{ duplicate$ empty$
-    { pop$ "" }
-    'skip$
-  if$
-}
-FUNCTION {emphasize}
-{ duplicate$ empty$
-    { pop$ "" }
-    { "\emph{" swap$ * "}" * }
-  if$
-}
-FUNCTION {bolden}
-{ duplicate$ empty$
-    { pop$ "" }
-    { "\textbf{" swap$ * "}" * }
-  if$
-}
-FUNCTION {tie.or.space.prefix}
-{ duplicate$ text.length$ #3 <
-    { "~" }
-    { " " }
-  if$
-  swap$
-}
-
-FUNCTION {capitalize}
-{ "u" change.case$ "t" change.case$ }
-
-FUNCTION {space.word}
-{ " " swap$ * " " * }
- % Here are the language-specific definitions for explicit words.
- % Each function has a name bbl.xxx where xxx is the English word.
- % The language selected here is ENGLISH
-FUNCTION {bbl.and}
-{ "and"}
-
-FUNCTION {bbl.etal}
-{ "et~al." }
-
-FUNCTION {bbl.editors}
-{ "eds." }
-
-FUNCTION {bbl.editor}
-{ "ed." }
-
-FUNCTION {bbl.edby}
-{ "edited by" }
-
-FUNCTION {bbl.edition}
-{ "edn." }
-
-FUNCTION {bbl.volume}
-{ "vol." }
-
-FUNCTION {bbl.of}
-{ "of" }
-
-FUNCTION {bbl.number}
-{ "no." }
-
-FUNCTION {bbl.nr}
-{ "no." }
-
-FUNCTION {bbl.in}
-{ "in" }
-
-FUNCTION {bbl.pages}
-{ "pp." }
-
-FUNCTION {bbl.page}
-{ "p." }
-
-FUNCTION {bbl.chapter}
-{ "chap." }
-
-FUNCTION {bbl.techrep}
-{ "Tech. Rep." }
-
-FUNCTION {bbl.mthesis}
-{ "Master's thesis" }
-
-FUNCTION {bbl.phdthesis}
-{ "Ph.D. thesis" }
-
-MACRO {jan} {"Jan."}
-
-MACRO {feb} {"Feb."}
-
-MACRO {mar} {"Mar."}
-
-MACRO {apr} {"Apr."}
-
-MACRO {may} {"May"}
-
-MACRO {jun} {"Jun."}
-
-MACRO {jul} {"Jul."}
-
-MACRO {aug} {"Aug."}
-
-MACRO {sep} {"Sep."}
-
-MACRO {oct} {"Oct."}
-
-MACRO {nov} {"Nov."}
-
-MACRO {dec} {"Dec."}
-
-MACRO {acmcs} {"ACM Computing Surveys"}
-
-MACRO {acta} {"Acta Informatica"}
-
-MACRO {cacm} {"Communications of the ACM"}
-
-MACRO {ibmjrd} {"IBM Journal of Research and Development"}
-
-MACRO {ibmsj} {"IBM Systems Journal"}
-
-MACRO {ieeese} {"IEEE Transactions on Software Engineering"}
-
-MACRO {ieeetc} {"IEEE Transactions on Computers"}
-
-MACRO {ieeetcad}
- {"IEEE Transactions on Computer-Aided Design of Integrated Circuits"}
-
-MACRO {ipl} {"Information Processing Letters"}
-
-MACRO {jacm} {"Journal of the ACM"}
-
-MACRO {jcss} {"Journal of Computer and System Sciences"}
-
-MACRO {scp} {"Science of Computer Programming"}
-
-MACRO {sicomp} {"SIAM Journal on Computing"}
-
-MACRO {tocs} {"ACM Transactions on Computer Systems"}
-
-MACRO {tods} {"ACM Transactions on Database Systems"}
-
-MACRO {tog} {"ACM Transactions on Graphics"}
-
-MACRO {toms} {"ACM Transactions on Mathematical Software"}
-
-MACRO {toois} {"ACM Transactions on Office Information Systems"}
-
-MACRO {toplas} {"ACM Transactions on Programming Languages and Systems"}
-
-MACRO {tcs} {"Theoretical Computer Science"}
-FUNCTION {bibinfo.check}
-{ swap$
-  duplicate$ missing$
-    {
-      pop$ pop$
-      ""
-    }
-    { duplicate$ empty$
-        {
-          swap$ pop$
-        }
-        { swap$
-          pop$
-        }
-      if$
-    }
-  if$
-}
-FUNCTION {bibinfo.warn}
-{ swap$
-  duplicate$ missing$
-    {
-      swap$ "missing " swap$ * " in " * cite$ * warning$ pop$
-      ""
-    }
-    { duplicate$ empty$
-        {
-          swap$ "empty " swap$ * " in " * cite$ * warning$
-        }
-        { swap$
-          pop$
-        }
-      if$
-    }
-  if$
-}
-STRINGS  { bibinfo}
-INTEGERS { nameptr namesleft numnames }
-
-FUNCTION {format.names}
-{ 'bibinfo :=
-  duplicate$ empty$ 'skip$ {
-  's :=
-  "" 't :=
-  #1 'nameptr :=
-  s num.names$ 'numnames :=
-  numnames 'namesleft :=
-    { namesleft #0 > }
-    { s nameptr
-      "{f.~}{vv~}{ll}{, jj}"
-      format.name$
-      bibinfo bibinfo.check
-      't :=
-      nameptr #1 >
-        {
-          namesleft #1 >
-            { ", " * t * }
-            {
-              numnames #2 >
-                { "," * }
-                'skip$
-              if$
-              s nameptr "{ll}" format.name$ duplicate$ "others" =
-                { 't := }
-                { pop$ }
-              if$
-              t "others" =
-                {
-                  " " * bbl.etal emphasize *
-                }
-                {
-                  bbl.and
-                  space.word * t *
-                }
-              if$
-            }
-          if$
-        }
-        't
-      if$
-      nameptr #1 + 'nameptr :=
-      namesleft #1 - 'namesleft :=
-    }
-  while$
-  } if$
-}
-FUNCTION {format.names.ed}
-{
-  format.names
-}
-FUNCTION {format.key}
-{ empty$
-    { key field.or.null }
-    { "" }
-  if$
-}
-
-FUNCTION {format.authors}
-{ author "author" format.names
-}
-FUNCTION {get.bbl.editor}
-{ editor num.names$ #1 > 'bbl.editors 'bbl.editor if$ }
-
-FUNCTION {format.editors}
-{ editor "editor" format.names duplicate$ empty$ 'skip$
-    {
-      "," *
-      " " *
-      get.bbl.editor
-      *
-    }
-  if$
-}
-FUNCTION {format.note}
-{
- note empty$
-    { "" }
-    { note #1 #1 substring$
-      duplicate$ "{" =
-        'skip$
-        { output.state mid.sentence =
-          { "l" }
-          { "u" }
-        if$
-        change.case$
-        }
-      if$
-      note #2 global.max$ substring$ * "note" bibinfo.check
-    }
-  if$
-}
-
-FUNCTION {format.title}
-{ title
-  duplicate$ empty$ 'skip$
-    { "t" change.case$ }
-  if$
-  "title" bibinfo.check
-}
-FUNCTION {format.full.names}
-{'s :=
- "" 't :=
-  #1 'nameptr :=
-  s num.names$ 'numnames :=
-  numnames 'namesleft :=
-    { namesleft #0 > }
-    { s nameptr
-      "{vv~}{ll}" format.name$
-      't :=
-      nameptr #1 >
-        {
-          namesleft #1 >
-            { ", " * t * }
-            {
-              s nameptr "{ll}" format.name$ duplicate$ "others" =
-                { 't := }
-                { pop$ }
-              if$
-              t "others" =
-                {
-                  " " * bbl.etal emphasize *
-                }
-                {
-                  numnames #2 >
-                    { "," * }
-                    'skip$
-                  if$
-                  bbl.and
-                  space.word * t *
-                }
-              if$
-            }
-          if$
-        }
-        't
-      if$
-      nameptr #1 + 'nameptr :=
-      namesleft #1 - 'namesleft :=
-    }
-  while$
-}
-
-FUNCTION {author.editor.key.full}
-{ author empty$
-    { editor empty$
-        { key empty$
-            { cite$ #1 #3 substring$ }
-            'key
-          if$
-        }
-        { editor format.full.names }
-      if$
-    }
-    { author format.full.names }
-  if$
-}
-
-FUNCTION {author.key.full}
-{ author empty$
-    { key empty$
-         { cite$ #1 #3 substring$ }
-          'key
-      if$
-    }
-    { author format.full.names }
-  if$
-}
-
-FUNCTION {editor.key.full}
-{ editor empty$
-    { key empty$
-         { cite$ #1 #3 substring$ }
-          'key
-      if$
-    }
-    { editor format.full.names }
-  if$
-}
-
-FUNCTION {make.full.names}
-{ type$ "book" =
-  type$ "inbook" =
-  or
-    'author.editor.key.full
-    { type$ "proceedings" =
-        'editor.key.full
-        'author.key.full
-      if$
-    }
-  if$
-}
-
-FUNCTION {output.bibitem}
-{ newline$
-  "\bibitem[{" write$
-  label write$
-  ")" make.full.names duplicate$ short.list =
-     { pop$ }
-     { * }
-   if$
-  "}]{" * write$
-  cite$ write$
-  "}" write$
-  newline$
-  ""
-  before.all 'output.state :=
-}
-
-FUNCTION {n.dashify}
-{
-  't :=
-  ""
-    { t empty$ not }
-    { t #1 #1 substring$ "-" =
-        { t #1 #2 substring$ "--" = not
-            { "--" *
-              t #2 global.max$ substring$ 't :=
-            }
-            {   { t #1 #1 substring$ "-" = }
-                { "-" *
-                  t #2 global.max$ substring$ 't :=
-                }
-              while$
-            }
-          if$
-        }
-        { t #1 #1 substring$ *
-          t #2 global.max$ substring$ 't :=
-        }
-      if$
-    }
-  while$
-}
-
-FUNCTION {word.in}
-{ bbl.in capitalize
-  " " * }
-
-FUNCTION {format.date}
-{ year "year" bibinfo.check duplicate$ empty$
-    {
-      "empty year in " cite$ * "; set to ????" * warning$
-       pop$ "????"
-    }
-    'skip$
-  if$
-  extra.label *
-  before.all 'output.state :=
-  " (" swap$ * ")" *
-}
-FUNCTION {format.btitle}
-{ title "title" bibinfo.check
-  duplicate$ empty$ 'skip$
-    {
-      emphasize
-    }
-  if$
-}
-FUNCTION {either.or.check}
-{ empty$
-    'pop$
-    { "can't use both " swap$ * " fields in " * cite$ * warning$ }
-  if$
-}
-FUNCTION {format.bvolume}
-{ volume empty$
-    { "" }
-    { bbl.volume volume tie.or.space.prefix
-      "volume" bibinfo.check * *
-      series "series" bibinfo.check
-      duplicate$ empty$ 'pop$
-        { swap$ bbl.of space.word * swap$
-          emphasize * }
-      if$
-      "volume and number" number either.or.check
-    }
-  if$
-}
-FUNCTION {format.number.series}
-{ volume empty$
-    { number empty$
-        { series field.or.null }
-        { series empty$
-            { number "number" bibinfo.check }
-            { output.state mid.sentence =
-                { bbl.number }
-                { bbl.number capitalize }
-              if$
-              number tie.or.space.prefix "number" bibinfo.check * *
-              bbl.in space.word *
-              series "series" bibinfo.check *
-            }
-          if$
-        }
-      if$
-    }
-    { "" }
-  if$
-}
-
-FUNCTION {format.edition}
-{ edition duplicate$ empty$ 'skip$
-    {
-      output.state mid.sentence =
-        { "l" }
-        { "t" }
[TRUNCATED]

To get the complete diff run:
    svnlook diff /svnroot/pomp -r 1021


More information about the pomp-commits mailing list