Package: mrds 2.3.0

Laura Marshall

mrds: Mark-Recapture Distance Sampling

Animal abundance estimation via conventional, multiple covariate and mark-recapture distance sampling (CDS/MCDS/MRDS). Detection function fitting is performed via maximum likelihood. Also included are diagnostics and plotting for fitted detection functions. Abundance estimation is via a Horvitz-Thompson-like estimator.

Authors:Jeff Laake <[email protected]>, David Borchers <[email protected]>, Len Thomas <[email protected]>, David Miller <[email protected]>, Jon Bishop and Jonah McArthur

mrds_2.3.0.tar.gz
mrds_2.3.0.zip(r-4.5)mrds_2.3.0.zip(r-4.4)mrds_2.3.0.zip(r-4.3)
mrds_2.3.0.tgz(r-4.4-any)mrds_2.3.0.tgz(r-4.3-any)
mrds_2.3.0.tar.gz(r-4.5-noble)mrds_2.3.0.tar.gz(r-4.4-noble)
mrds_2.3.0.tgz(r-4.4-emscripten)mrds_2.3.0.tgz(r-4.3-emscripten)
mrds.pdf |mrds.html
mrds/json (API)
NEWS

# Install 'mrds' in R:
install.packages('mrds', repos = c('https://distancedevelopment.r-universe.dev', 'https://cloud.r-project.org'))

Peer review:

Bug tracker:https://github.com/distancedevelopment/mrds/issues

Datasets:
  • book.tee.data - Golf tee data used in chapter 6 of Advanced Distance Sampling examples
  • lfbcvi - Black-capped vireo mark-recapture distance sampling analysis
  • lfgcwa - Golden-cheeked warbler mark-recapture distance sampling analysis
  • pronghorn - Pronghorn aerial survey data from Wyoming
  • ptdata.distance - Single observer point count data example from Distance
  • ptdata.dual - Simulated dual observer point count data
  • ptdata.removal - Simulated removal observer point count data
  • ptdata.single - Simulated single observer point count data
  • stake77 - Wooden stake data from 1977 survey
  • stake78 - Wooden stake data from 1978 survey

On CRAN:

18 exports 4 stars 3.43 score 10 dependencies 6 dependents 12 mentions 75 scripts 1.2k downloads

Last updated 7 months agofrom:689a9e9531. Checks:OK: 5 NOTE: 2. Indexed: yes.

TargetResultDate
Doc / VignettesOKSep 10 2024
R-4.5-winNOTESep 10 2024
R-4.5-linuxNOTESep 10 2024
R-4.4-winOKSep 10 2024
R-4.4-macOKSep 10 2024
R-4.3-winOKSep 10 2024
R-4.3-macOKSep 10 2024

Exports:add_df_covar_lineadd.df.covar.lineassign.parcheck.monocreate.binscreate.ddfobjddfddf.gofDeltaMethoddet.tablesdetfctdhtdht.sep_dist_tablep.dist.tableqqplot.ddfsolvecovvarn

Dependencies:latticeMatrixmgcvnlmenloptrnumDerivoptimxpracmaRsolnptruncnorm

Readme and manuals

Help Manual

Help pageTopics
Mark-Recapture Distance Sampling (mrds)mrds-package mrds
Add covariate levels detection function plotsadd.df.covar.line add_df_covar_line
Check order of adjustment termsadj.check.order
Akaike's An Information Criterion for detection functionsAIC.ddf AIC.ds AIC.io AIC.io.fi AIC.rem AIC.rem.fi AIC.trial AIC.trial.fi
Get the apex for a gamma detection functionapex.gamma
Assign default values to list elements that have not been already assignedassign.default.values
Average detection function line for plottingaverage.line
Average conditional detection function line for plottingaverage.line.cond
Golf tee data used in chapter 6 of Advanced Distance Sampling examplesbook.tee.data
Find se of average p and Ncalc.se.Np
Cumulative distribution function (cdf) for fitted distance sampling detection functioncdf.ds
CDS function definitioncds
Check parameters bounds during optimisationscheck.bounds
Check that a detection function is monotonecheck.mono
Extract coefficientscoef.ds coef.io coef.io.fi coef.rem coef.rem.fi coef.trial coef.trial.fi coefficients
Horvitz-Thompson estimates 1/p_i or s_i/p_icompute.Nht
Covered region estimate of abundance from Horvitz-Thompson-like estimatorcovered.region.dht
Create bins from a set of binned distances and a set of cutpoints.create.bins
create.command.filecreate.command.file
Create a model frame for ddf fittingcreate.model.frame
Creates structures needed to compute abundance and variancecreate.varstructure
Distance Detection Function Fittingddf
CDS/MCDS Distance Detection Function Fittingddf.ds
Goodness of fit tests for distance sampling modelsddf.gof gof.io gof.io.fi gof.rem gof.rem.fi gof.trial gof.trial.fi
Mark-Recapture Distance Sampling (MRDS) IO - PIddf.io
Mark-Recapture Distance Sampling (MRDS) IO - FIddf.io.fi
Mark-Recapture Distance Sampling (MRDS) Removal - PIddf.rem
Mark-Recapture Distance Sampling (MRDS) Removal - FIddf.rem.fi
Mark-Recapture Distance Sampling (MRDS) Trial Configuration - PIddf.trial
Mark-Recapture Analysis of Trial Configuration - FIddf.trial.fi
Numeric Delta Method approximation for the variance-covariance matrixDeltaMethod
Observation detection tablesdet.tables
Fit detection function using key-adjustment functionsdetfct.fit
Fit detection function using key-adjustment functionsdetfct.fit.opt
Density and abundance estimates and variancesdht
Computes abundance estimates at specified parameter values using Horvitz-Thompson-like estimatordht.deriv
Variance and confidence intervals for density and abundance estimatesdht.se
Distance Sampling Functionsds.function
Log-likelihood computation for distance sampling dataflnl flpt.lnl
Hessian computation for fitted distance detection function model parametersflt.var
Compute value of p(0) using a logit formulationg0
Extraction and assignment of parameters to vectorgetpar
Compute chi-square goodness-of-fit test for ds modelsgof.ds
Integral of pdf of distancesgstdint
Plot histogram linehistline
Integrate a logistic detection functionintegratedetfct.logistic
Analytically integrate logistic detection functionintegratelogistic.analytic
Numerically integrate pdf of observed distances over specified rangesintegratepdf
Iterative offset GLM/GAM for fitting detection functionio.glm
Collection of functions for logistic detection functionsis.linear.logistic
Is a logit model constant for all observations?is.logistic.constant
Threshold key functionkeyfct.th1
Threshold key functionkeyfct.th2
Two-part normal key functionkeyfct.tpn two-part-normal
Black-capped vireo mark-recapture distance sampling analysislfbcvi
Golden-cheeked warbler mark-recapture distance sampling analysislfgcwa
Logistic as a function of covariateslogisticbyx
Logistic as a function of distancelogisticbyz
Logistic detection functionlogisticdetfct
Logistic for duplicates as a function of covariateslogisticdupbyx
Logistic for duplicates as a function of covariates (fast)logisticdupbyx_fast
Logit functionlogit
log-likelihood value for a fitted detection functionlogLik.ddf logLik.ds logLik.io logLik.io.fi logLik.rem logLik.rem.fi logLik.trial logLik.trial.fi
MCDS function definitionmcds
Run MCDS.exe as a backend for mrdsMCDS MCDS.exe mcds_dot_exe
Tips on optimisation issues in 'mrds' modelsmrds_opt
Compute estimated abundance in covered (sampled) regionNCovered NCovered.ds NCovered.io NCovered.io.fi NCovered.rem NCovered.rem.fi NCovered.trial NCovered.trial.fi
Wrapper around 'nlminb'nlminb_wrapper
Double-platform detection probabilityp.det
Distribution of probabilities of detectionp.dist.table p_dist_table
Parse optimx results and present a nice objectparse.optimx
Compute probability that a object was detected by at least one observerpdot.dsr.integrate.logistic
Plot conditional detection function from distance sampling modelplot_cond
Layout for plot methods in mrdsplot_layout
Plot unconditional detection function from distance sampling modelplot_uncond
Observation detection tablesplot.det.tables
Plot fit of detection functions and histograms of data from distance sampling modelplot.ds
Plot fit of detection functions and histograms of data from distance sampling independent observer ('io') modelplot.io
Plot fit of detection functions and histograms of data from distance sampling independent observer model with full independence ('io.fi')plot.io.fi
Plot fit of detection functions and histograms of data from removal distance sampling modelplot.rem
Plot fit of detection functions and histograms of data from removal distance sampling modelplot.rem.fi
Plot fit of detection functions and histograms of data from distance sampling trial observer modelplot.trial
Plot fit of detection functions and histograms of data from distance sampling trial observer modelplot.trial.fi
Predictions from 'mrds' modelspredict predict.ddf predict.ds predict.io predict.io.fi predict.rem predict.rem.fi predict.trial predict.trial.fi
Simple pretty printer for distance sampling analysesprint.ddf
Prints results of goodness of fit tests for detection functionsprint.ddf.gof
Print results of observer detection tablesprint.det.tables
Prints density and abundance estimatesprint.dht
Print distribution of probabilities of detectionprint.p_dist_table
Print summary of distance detection function model objectprint.summary.ds
Print summary of distance detection function model objectprint.summary.io
Print summary of distance detection function model objectprint.summary.io.fi
Print summary of distance detection function model objectprint.summary.rem
Print summary of distance detection function model objectprint.summary.rem.fi
Print summary of distance detection function model objectprint.summary.trial
Print summary of distance detection function model objectprint.summary.trial.fi
Derivatives for variance of average p and average p(0) varianceprob.deriv
Average p and average p(0) varianceprob.se
Process data for fitting distance sampling detection functionprocess.data
Pronghorn aerial survey data from Wyomingpronghorn
Single observer point count data example from Distanceptdata.distance
Simulated dual observer point count dataptdata.dual
Simulated removal observer point count dataptdata.removal
Simulated single observer point count dataptdata.single
Quantile-quantile plot and goodness of fit tests for detection functionsqqplot.ddf
Iterative offset model fitting of mark-recapture with removal modelrem.glm
Calculate the parameter rescaling for parameters associated with covariatesrescale_pars
Generate data from a fitted detection function and refit the modelsample_ddf
Set parameter boundssetbounds
Creates design matrix for covariates in detection functionsetcov
Set initial values for detection function based on distance samplingsethazard setinitial.ds
Simulation of distance sampling data via mixture models Allows one to simulate line transect distance sampling data using a mixture of half-normal detection functions.sim.mix
Invert of covariance matricessolvecov
Wooden stake data from 1977 surveystake77
Wooden stake data from 1978 surveystake78
Summary of distance detection function model objectsummary.ds
Summary of distance detection function model objectsummary.io
Summary of distance detection function model objectsummary.io.fi
Summary of distance detection function model objectsummary.rem
Summary of distance detection function model objectsummary.rem.fi
Summary of distance detection function model objectsummary.trial
Summary of distance detection function model objectsummary.trial.fi
Extrapolate Horvitz-Thompson abundance estimates to entire surveyed regionsurvey.region.dht
Test validity for histogram breaks(cutpoints)test.breaks
Compute empirical variance of encounter ratecovn varn