RunTime {BTSPAS}R Documentation

Compute percentiles of the run timing distribution.


Take the posterior sample of U[1,...nstrata] and compute the percentiles of the run timing. This uses the quantile() function from the "actuar" package which is designed to compute quantiles of grouped data.


RunTime(time, U, prob = seq(0, 1, 0.1))



List of sample weeks. It is assumed that there are no salmon prior to the first value


matrix of posterior samples. Each row is a sample from the posterior.


Quantiles of the run timing to estimate.


An MCMC object with samples from the posterior distribution. A series of graphs and text file are also created in the working directory. This information is now added to the fit object as well and so it is unlikely that you will use this function.


Bonner, S.J. and Schwarz, C. J.


Bonner, S. J., & Schwarz, C. J. (2011). Smoothing population size estimates for Time-Stratified Mark-Recapture experiments Using Bayesian P-Splines. Biometrics, 67, 1498-1507.

Schwarz, C. J., & Dempson, J. B. (1994). Mark-recapture estimation of a salmon smolt population. Biometrics, 50, 98-108.

Schwarz, C.J., D. Pickard, K. Marine and S.J. Bonner. 2009. Juvenile Salmonid Outmigrant Monitoring Evaluation, Phase II - December 2009. Final Technical Memorandum for the Trinity River Restoration Program, Weaverville, CA. 155 pp. + appendices available at

[Package BTSPAS version 2021.1.1 Index]