Article

On thinning of chains in MCMC

Wiley
Methods in Ecology and Evolution
Authors:
To read the full-text of this research, you can request a copy directly from the authors.

Abstract

1. Markov chain Monte Carlo (MCMC) is a simulation technique that has revolutionised the analysis of ecological data, allowing the fitting of complex models in a Bayesian framework. Since 2001, there have been nearly 200 papers using MCMC in publications of the Ecological Society of America and the British Ecological Society, including more than 75 in the journal Ecology and 35 in the Journal of Applied Ecology. 2. We have noted that many authors routinely ‘thin’ their simulations, discarding all but every kth sampled value; of the studies we surveyed with details on MCMC implementation, 40% reported thinning. 3. Thinning is often unnecessary and always inefficient, reducing the precision with which features of the Markov chain are summarised. The inefficiency of thinning MCMC output has been known since the early 1990’s, long before MCMC appeared in ecological publications. 4. We discuss the background and prevalence of thinning, illustrate its consequences, discuss circumstances when it might be regarded as a reasonable option and recommend against routine thinning of chains unless necessitated by computer memory limitations.

No full-text available

Request Full-text Paper PDF

To read the full-text of this research,
you can request a copy directly from the authors.

... While thinning indeed reduces the autocorrelation of the samples generated by CHRR, the reduction comes at the cost of producing an approximation of the target distribution that is less accurate. Indeed, thinning is known to be statistically inefficient in all but very few cases [48,49]. ...
... [48] argued that for thinning to be beneficial, the time cost t N,τ has to grow slower with τ than the ESS, indicating that thinning is not advantageous for every combination of sampling problem and MCMC algorithm. In this vein, [49] criticize the routine application of thinning for applications in ecology, where thinning is often detrimental to sampling efficiency. ...
... Despite thinning being a common MCMC practice, it is still controversially discussed. Statisticians have pointed out that thinning is often not necessary and that it typically wastes computational resources, unless the cost of using the samples is high [48,49]. Even then, Geyer argues that a thinning constant of two or three times the problem dimension should be suited in nearly all cases. ...
Article
Full-text available
Thinning is a sub-sampling technique to reduce the memory footprint of Markov chain Monte Carlo. Despite being commonly used, thinning is rarely considered efficient. For sampling constraint-based models, a highly relevant use-case in systems biology, we here demonstrate that thinning boosts computational and, thereby, sampling efficiencies of the widely used Coordinate Hit-and-Run with Rounding (CHRR) algorithm. By benchmarking CHRR with thinning with simplices and genome-scale metabolic networks of up to thousands of dimensions, we find a substantial increase in computational efficiency compared to unthinned CHRR, in our examples by orders of magnitude, as measured by the effective sample size per time (ESS/t), with performance gains growing with polytope (effective network) dimension. Using a set of benchmark models we derive a ready-to-apply guideline for tuning thinning to efficient and effective use of compute resources without requiring additional coding effort. Our guideline is validated using three (out-of-sample) large-scale networks and we show that it allows sampling convex polytopes uniformly to convergence in a fraction of time, thereby unlocking the rigorous investigation of hitherto intractable models. The derivation of our guideline is explained in detail, allowing future researchers to update it as needed as new model classes and more training data becomes available. CHRR with deliberate utilization of thinning thereby paves the way to keep pace with progressing model sizes derived with the constraint-based reconstruction and analysis (COBRA) tool set. Sampling and evaluation pipelines are available at https://jugit.fz-juelich.de/IBG-1/ModSim/fluxomics/chrrt.
... We formatted the capture-recovery data in multinomial arrays to reduce computational requirements (Table S2) We fit the band-recovery models in JAGS (Plummer 2003) using the jagsUI package (Kellner 2016). We sampled 5 chains of 35,000 iterations using a Markov chain Monte Carlo (MCMC) algorithm, discarded the first 5,000 iterations as burn-in, and retained all iterations (Link and Eaton 2012), for a posterior sample of 150,000. We report medians of posterior distributions and 95% Bayesian credible intervals (BCI) in the text, tables, and figures. ...
... (Plummer 2003), run from the jagsUI package in R (Kellner 2016). In JAGS, we ran 3 MCMC chains for 10,000 iterations with a burn-in period of 5,000 iterations, for a full posterior sample of 15,000 (Link and Eaton 2012). We considered models that had Ȓ < 1.01 at each parameter node and good mixture on trace plots to have reached convergence. ...
Article
Outbreaks of highly pathogenic avian influenza virus in wild animals highlight the need for disease surveillance in wild birds to improve our understanding of their role as reservoirs and dispersers, and potential threats to domestic poultry and wild bird populations. Surveillance for avian influenza varies in its approach, objectives, and coordination with other monitoring efforts. For waterfowl, a common host to avian influenza viruses, banding represents a concerted effort of capturing and marking thousands of individuals annually to estimate survival and harvest rates, but users of these data have generally taken a conservative approach to remove any banded birds from analyses that had a sample taken for disease surveillance during capture. We tested for differences in survival and encounter probabilities of blue‐winged teal ( Spatula discors ) marked ( n = 21,702 teal) and sampled for disease surveillance ( n = 4,216) during the nonbreeding season in Louisiana, USA, from 2016 to 2023. Although we found no consistent effect of collecting biological samples on survival probability, including an additional test showing no detectable effects of sampling for disease surveillance with oropharyngeal and cloacal swabs versus sampling with swabs and a syringe‐drawn blood sample, wide 95% credible intervals on the posterior survival estimates (mean 0.36 difference between upper and lower values across all year‐sex‐sampling groups; 0.44 for sampling type groups) indicated low statistical power to detect an effect. Seber recovery probability during the first interval following sampling was lower among birds sampled using swabs only, but we assume this stems from low sample sizes rather than an effect of collecting biological samples. Because recovery probabilities can vary as a function of individual covariates, we also examined direct recovery probabilities and observed no meaningful effect of disease surveillance sampling type but strong effects of capture date, suggesting the effect on Seber recovery probability may have been due to heterogeneity in exposure to natural and harvest mortality risks. Although we suggest that aligning disease surveillance sample collection efforts with landscape‐scale waterfowl banding efforts may have little effect on observed demographic rates, additional studies with larger sample sizes are likely needed to provide the statistical power necessary to formally conclude no effect of biological sampling on survival probabilities.
... MacEachern and Berliner (1994) go so far as to provide a 'justification for the ban against subsampling'. Link and Eaton (2011) write that "Thinning is often unnecessary and always inefficient". In discussing thinning of the Gibbs sampler, Gamerman and Lopes (2006) say: "There is no gain in efficiency, however, by this approach and estimation is shown below to be always less precise than retaining all chain values." ...
... He gives some qualitative remarks about this effect, but ultimately concludes that it is usually a negligible benefit because the autocorrelations in the Markov chain decay exponentially fast. Link and Eaton (2011) also acknowledge this possibility in their discussion as does Neal (1993, page 106). ...
Preprint
It is common to subsample Markov chain output to reduce the storage burden. Geyer (1992) shows that discarding k1k-1 out of every k observations will not improve statistical efficiency, as quantified through variance in a given computational budget. That observation is often taken to mean that thinning MCMC output cannot improve statistical efficiency. Here we suppose that it costs one unit of time to advance a Markov chain and then θ>0\theta>0 units of time to compute a sampled quantity of interest. For a thinned process, that cost θ\theta is incurred less often, so it can be advanced through more stages. Here we provide examples to show that thinning will improve statistical efficiency if θ\theta is large and the sample autocorrelations decay slowly enough. If the lag 1\ell\ge1 autocorrelations of a scalar measurement satisfy ρρ+10\rho_\ell\ge\rho_{\ell+1}\ge0, then there is always a θ<\theta<\infty at which thinning becomes more efficient for averages of that scalar. Many sample autocorrelation functions resemble first order AR(1) processes with ρ=ρ\rho_\ell =\rho^{|\ell|} for some 1<ρ<1-1<\rho<1. For an AR(1) process it is possible to compute the most efficient subsampling frequency k. The optimal k grows rapidly as ρ\rho increases towards 1. The resulting efficiency gain depends primarily on θ\theta, not ρ\rho. Taking k=1 (no thinning) is optimal when ρ0\rho\le0. For ρ>0\rho>0 it is optimal if and only if θ(1ρ)2/(2ρ)\theta \le (1-\rho)^2/(2\rho). This efficiency gain never exceeds 1+θ1+\theta. This paper also gives efficiency bounds for autocorrelations bounded between those of two AR(1) processes.
... To reduce the inherent correlation of the initial subset samples, one could use HMC combined with a thinning procedure [29,30]. Specifically, it is recommended to thin the chain by subsampling every k samples, where k denotes the thinning lag. ...
... The reader should be aware that the thinning is not, in general, a recommended practice for approximating means, variances or percentiles. It is often better to use the full correlated chain rather than the thinned de-correlated one [29,30]. However, in the context of Subset Simulation, the number of samples used to evaluate the conditional probability per subset is fixed. ...
Preprint
This paper studies a non-random-walk Markov Chain Monte Carlo method, namely the Hamiltonian Monte Carlo (HMC) method in the context of Subset Simulation used for structural reliability analysis. The HMC method relies on a deterministic mechanism inspired by Hamiltonian dynamics to propose samples following a target probability distribution. The method alleviates the random walk behavior to achieve a more effective and consistent exploration of the probability space compared to standard Gibbs or Metropolis-Hastings techniques. After a brief review of the basic concepts of the HMC method and its computational details, two algorithms are proposed to facilitate the application of the HMC method to Subset Simulation in structural reliability analysis. Next, the behavior of the two HMC algorithms is illustrated using simple probability distribution models. Finally, the accuracy and efficiency of Subset Simulation employing the two HMC algorithms are tested using various reliability examples. The supporting source code and data are available for download at (the URL that will become available once the paper is accepted).
... (4) greatly, but also simplifies the interpretation of each sample individually. It is to be noted that thinning reduces the statistics [29,30] (i.e. our results are less precise after thinning), but we still end up with a sufficiently large sample. ...
... The Instagram model simulation used two MCMC chains of 100,000 iterations with a burnin of 10,000 and no thinning. The use of thinning for achieving higherprecision estimates from posterior samples is questionable when compared to simply running longer chains (44). While no best practice has been established for how long an unthinned chain should be, Christensen et al. (45) advised: "Unless there is severe autocorrelation, e.g., high correlation with, say [lag]=30, we don't believe that thinning is worthwhile". ...
Preprint
Full-text available
Using Instagram data from 166 individuals, we applied machine learning tools to successfully identify markers of depression. Statistical features were computationally extracted from 43,950 participant Instagram photos, using color analysis, metadata components, and algorithmic face detection. Resulting models outperformed general practitioners' average diagnostic success rate for depression. These results held even when the analysis was restricted to posts made before depressed individuals were first diagnosed. Photos posted by depressed individuals were more likely to be bluer, grayer, and darker. Human ratings of photo attributes (happy, sad, etc.) were weaker predictors of depression, and were uncorrelated with computationally-generated features. These findings suggest new avenues for early screening and detection of mental illness.
... Thinning here refers to the discarding of all but every k-th sample for an MCMC sample chain obtained from the posterior distribution. This is performed for several reasons (see [34]): it reduces high autocorrelations in the MCMC chain, saves computer storage space, and reduces processing time for computing derived posterior quantities. However, by carelessly throwing away samples, a glaring fault of thinning is that samples from thinned chains are inherently less accurate than that from the full chain. ...
Preprint
This paper introduces a new way to compact a continuous probability distribution F into a set of representative points called support points. These points are obtained by minimizing the energy distance, a statistical potential measure initially proposed by Sz\'ekely and Rizzo (2004) for testing goodness-of-fit. The energy distance has two appealing features. First, its distance-based structure allows us to exploit the duality between powers of the Euclidean distance and its Fourier transform for theoretical analysis. Using this duality, we show that support points converge in distribution to F, and enjoy an improved error rate to Monte Carlo for integrating a large class of functions. Second, the minimization of the energy distance can be formulated as a difference-of-convex program, which we manipulate using two algorithms to efficiently generate representative point sets. In simulation studies, support points provide improved integration performance to both Monte Carlo and a specific Quasi-Monte Carlo method. Two important applications of support points are then highlighted: (a) as a way to quantify the propagation of uncertainty in expensive simulations, and (b) as a method to optimally compact Markov chain Monte Carlo (MCMC) samples in Bayesian computation.
... One has to rule out Monte Carlo methods due to the separation requirement: random points exhibit clustering [11], which makes deterministic post-processing, in particular by energy minimization, costly. Similarly, mitigating the clustering by purely probabilistic approaches, as for example thinning discussed in [42], or by sampling from a random process with repulsive properties [1,4], does not generally yield satisfying results, since the separation can only be guaranteed on average. Instead, we turn to the quasi-Monte Carlo (Q-MC) approach. ...
Preprint
We present an algorithm for producing discrete distributions with a prescribed nearest-neighbor distance function. Our approach is a combination of quasi-Monte Carlo (Q-MC) methods and weighted Riesz energy minimization: the initial distribution is a stratified Q-MC sequence with some modifications; a suitable energy functional on the configuration space is then minimized to ensure local regularity. The resulting node sets are good candidates for building meshless solvers and interpolants, as well as for other purposes where a point cloud with a controlled separation-covering ratio is required. Applications of a three-dimensional implementation of the algorithm, in particular to atmospheric modeling, are also given.
... This is particularly relevant if a compact set of samples is desired, due to e.g. memory or post-processing constraints [71]. ...
Preprint
Full-text available
This thesis explores adaptive inference as a tool to characterize quantum systems using experimental data, with applications in sensing, calibration, control, and metrology. I propose and test algorithms for learning Hamiltonian and Kraus operators using Bayesian experimental design and advanced Monte Carlo techniques, including Sequential and Hamiltonian Monte Carlo. Application to the characterization of quantum devices from IBMQ shows a robust performance, surpassing the built-in characterization functions of Qiskit for the same number of measurements. Introductions to Bayesian statistics, experimental design, and numerical integration are provided, as well as an overview of existing literature.
... We ran models within a Bayesian framework using Markov chain Monte Carlo simulations via package R 'jag-sUI' (Kellner and Meredith 2021). We ran three unthinned chains of 20 000 iterations, with the first 10 000 iterations discarded following an adaptation phase of 10 000 iterations (Link and Eaton 2012). After testing the sensitivity of prior distributions on parameter estimates, we used diffuse, normal distributions (mean = 0, variance = 1000) for all coefficient priors and a uniform (0,10) prior distribution for the standard deviation of the overdispersion parameter. ...
Article
Full-text available
Variation in animal abundance is shaped by scale‐dependent habitat, competition, and anthropogenic influences. Coyotes Canis latrans have dramatically increased in abundance while expanding their range over the past 100 years. Management goals typically seek to lower coyote populations to reduce their threats to humans, pets, livestock and sensitive prey. Despite their outsized ecological and social roles in the Americas, the factors affecting coyote abundance across their range remain unclear. We fit Royle–Nichols abundance models at two spatial scales in a Bayesian hierarchical framework to three years of data from 4587 camera trap sites arranged in 254 arrays across the contiguous USA to assess how habitat, large carnivores, anthropogenic development and hunting regulations affect coyote abundance. Coyote abundance was highest in southwestern USA and lowest in the northeast. Abundance responded to some factors as expected, including positive (soft mast, agriculture, grass/shrub habitat, urban–natural edge) and negative (latitude and forest cover) relationships. Colonization date had a negative relationship, suggesting coyote populations have not reached carrying capacity in recently colonized regions. Several relationships were scale‐dependent, including urban development, which was negative at local (100‐m) scales but positive at larger (5‐km) scales. Large carnivore effects were habitat‐dependent, with sometimes opposing relationships manifesting across variation in forest cover and urban development. Coyote abundance was higher where human hunting was permitted, and this relationship was strongest at local scales. These results, including a national map of coyote abundance, update ecological understanding of coyotes and can inform coyote management at local and landscape scales. These findings expand results from local studies suggesting that directly hunting coyotes does not decrease their abundance and may actually increase it. Ongoing large carnivore recoveries globally will likely affect subordinate carnivore abundance, but not in universally negative ways, and our work demonstrates how such effects can be habitat and scale dependent.
... We fitted models with package brms in R 28 and used the default uninformative prior distributions for fixed effects. We ran 4 Markov Chain Monte Carlo (MCMC) chains of 5,000 iterations, discarding 2,500 iterations during the warm-up period; we did not use thinning or discard iterations 29 . We ensured that MCMC chains converged by examining trace plots and using the Gelman-Rubin statistic 30 ( R value < 1.05). ...
Article
Full-text available
Black-bellied Whistling-Ducks (Dendrocygna autumnalis; BBWD) are rapidly expanding northward into the core range of the eastern Wood Duck (Aix sponsa; WODU), yet little is known about BBWD nesting ecology. Typical field methods to study cavity-nesting waterfowl (i.e., weekly nest monitoring) preclude a full understanding of important breeding information, including nest prospecting and parasitic egg laying. To address this, we used subcutaneous passive integrated transponder (PIT) tags embedded in adults and PIT tag readers mounted on nest boxes with the objective to (1) identify individuals that used nest boxes but were not physically captured on a nest, (2) quantify box visitation, and (3) quantify BBWD pair and WODU hen behaviors during the prospecting, laying, and incubation periods. We deployed RFID readers on 40 nest boxes from March–December 2022 in Louisiana with the potential to detect BBWD and WODU marked with PIT tags in 2020–2022. We detected 48 (BBWD n = 26, WODU n = 22) adults of both species via RFID readers, and 33% (n = 16) of individuals (50% of BBWD, n = 12; 14% of WODU, n = 3) were never otherwise recaptured in 2022, meaning that traditional field methods for cavity-nesting waterfowl fail to document a substantial number of birds potentially contributing to the population via parasitism. We also used Bayesian generalized linear models to determine that both species visited a similar number of “new” (< 1 year old) and “old” (> 1 year old) nest boxes (β = 0.66, CI = -0.30, 1.64). However, BBWD preferentially visited (and subsequently nested in) old boxes at a significantly higher rate than WODU (β = 1.32, CI = 0.97, 1.66). Due to the generalist nature and rapid expansion of BBWD, an apparent aversion to newly installed boxes was unexpected, especially since there were several successful WODU nests in the new boxes before BBWD began nesting in 2022. Our study is one of the first to evaluate BBWD nesting behaviors within the core WODU breeding range, and the first to use nest box-mounted PIT tag readers to observe BBWD behavior.
... Burn in menyatakan banyaknya periode sampel pertama pada proses MCMC yang tidak digunakan dalam perhitungan estimasi parameter [11]. Sementara itu, thin menyatakan periode pengambilan sampel pada urutan proses MCMC untuk digunakan dalam perhitungan estimasi parameter [12]. ...
... Unlike Gelman and Rubin (1992) and Stan, but in line with others (Geyer, 1992;Link & Eaton, 2012;Zitzmann & Hecht, 2019), we consider a single long chain consisting of consecutive values for the parameter of interest θ. This approach has the advantage of clarifying how the Gelman-Rubin diagnostic can later be adapted for our nonvisual procedure for screening for nonstationarity. ...
Preprint
Full-text available
Researchers working with intensive longitudinal designs often encounter the challenge of determining whether to relax the assumption of stationarity in their models. Given that these designs typically involve data from a large number of subjects (N ≫ 1), visual screening all time series can quickly become tedious. Even when conducted by experts, such screenings can lack accuracy. In this article, we propose a nonvisual procedure that enables fast and accurate screening. This procedure has potential to become a widely adopted approach for detecting nonstationarity and guiding model building in psychology and related fields, where intensive longitudinal designs are used and time series data are collected.
... Common regularising priors were used for all model parameters: normal distributions of mean 0 and standard deviation of 1 for intercepts and slopes coefficients, and exponential distributions of rate 2 for variance parameters. Each model ran on 3 chains, with a burn-in period of 1000 iterations, sampling for 3000 iterations, keeping all the sampled iterations (Link & Eaton, 2012). Convergence of parameter estimates was assessed visually and using the Gelman-Rubin diagnostic (Gelman & Rubin, 1992). ...
Article
Full-text available
Life history trade‐offs are one of the central tenets of evolutionary demography. Trade‐offs, depicting negative covariances between individuals' life history traits, can arise from genetic constraints, or from a finite amount of resources that each individual has to allocate in a zero‐sum game between somatic and reproductive functions. While theory predicts that trade‐offs are ubiquitous, empirical studies have often failed to detect such negative covariances in wild populations. One way to improve the detection of trade‐offs is by accounting for the environmental context, as trade‐off expression may depend on environmental conditions. However, current methodologies usually search for fixed covariances between traits, thereby ignoring their context dependence. Here, we present a hierarchical multivariate ‘covariance reaction norm’ model, adapted from Martin (2023), to help detect context dependence in the expression of life‐history trade‐offs using demographic data. The method allows continuous variation in the phenotypic correlation between traits. We validate the model on simulated data for both intraindividual and intergenerational trade‐offs. We then apply it to empirical datasets of yellow‐bellied marmots (Marmota flaviventer) and Soay sheep (Ovis aries) as a proof‐of‐concept showing that new insights can be gained by applying our methodology, such as detecting trade‐offs only in specific environments. We discuss its potential for application to many of the existing long‐term demographic datasets and how it could improve our understanding of trade‐off expression in particular, and life history theory in general.
... Data manipulation was done in R 4.2.2 using the "tidyverse" (Wickham et al., 2019) and "lubridate" (Grolemund and Wickham, 2011). Models were run with 4 chains of 1,000 warm up and 1,000 active sampling iterations of the posterior for each complete imputed dataset with no thinning (Link and Eaton, 2012) and a proposal acceptance (adaptive delta) set to 0.95 to control the sampler step size (Betancourt 2017). ...
Article
Cisco (Coregonus artedi) support an evolving commercial roe fishery in Wisconsin waters of Lake Superior. To monitor trends in spawning cisco abundance, fishery managers recently began estimating adult biomass and exploitation using fall hydroacoustic surveys, which were combined with gill net surveys to inform apportion-ments of acoustic data. The gill net survey design consisted of paired top-suspended and bottom-set gill nets, but only the sex ratios from top nets are currently used with the hydroacoustic surveys due to an assumption that cisco in Lake Superior are pelagic spawners. However, the vertical sex distribution of cisco during spawning aggregations has been described as dynamic, with males becoming more bottom-oriented throughout the spawning season. We used multilevel aggregated binomial regressions to: 1) determine if there is bias between top and bottom gill net catches of cisco for either sex and if it changes throughout the spawning season, 2) evaluate how the vertical distribution of males and females may create bias in sex ratios used to estimate exploitation, and 3) explore the effect that maturity (i.e., gonadal development) has on vertical distribution during spawning aggregations. We identified sex-specific bias in vertical catch location that has the potential to bias estimates of sex ratio, and the source of this bias may be attributable to maturity driven changes in behavior. These findings highlight a need for caution when relying on gill nets to apportion cisco sex ratios during spawning aggregations and provide support for a non-pelagic alternative hypothesis of spawning behavior.
... (4) greatly, but also simplifies the interpretation of each sample individually. It is to be noted that thinning reduces the statistics [29,30] (i.e. our results are less precise after thinning), but we still end up with a sufficiently large sample. ...
Preprint
Full-text available
The current scientific standard in PDF uncertainty estimation relies either on repeated fits over artificially generated data to arrive at Monte Carlo samples of best fits or on the Hessian method, which uses a quadratic expansion of the figure of merit, the χ2\chi^2-function. Markov Chain Monte Carlo methods allows one to access the uncertainties of PDFs without making use of quadratic approximations in a statistically sound procedure while at the same time preserving the correspondence between the sample and χ2\chi^2-value. Rooted in Bayesian statistics the χ2\chi^2-function is repeatedly sampled to obtain a set of PDFs that serves as a representation of the statistical distribution of the PDFs in their function space. After removing the dependence between the samples (the so-called autocorrelation) the set can be used to propagate the uncertainties to physical observables. The final result is an independent procedure to obtain PDF uncertainties that can be confronted by the state-of-the-art in order to ultimately arrive at a better understanding of the proton's structure.
... We fit models in a Bayesian framework using JAGS via the "r2jags" package in R (Version 4.2. 1, Plummer, 2003;R Core Team, 2022;Su et al., 2015). We fit all models with 8000 MCMC iterations with three un-thinned chains and a burn-in of 1000 iterations (Link & Eaton, 2012) and assured convergence using standard diagnostics. ...
Article
Full-text available
Generalized linear models (GLMs) are an integral tool in ecology. Like general linear models, GLMs assume linearity, which entails a linear relationship between independent and dependent variables. However, because this assumption acts on the link rather than the natural scale in GLMs, it is more easily overlooked. We reviewed recent ecological literature to quantify the use of linearity. We then used two case studies to confront the linearity assumption via two GLMs fit to empirical data. In the first case study we compared GLMs to generalized additive models (GAMs) fit to mammal relative abundance data. In the second case study we tested for linearity in occupancy models using passerine point‐count data. We reviewed 162 studies published in the last 5 years in five leading ecology journals and found less than 15% reported testing for linearity. These studies used transformations and GAMs more often than they reported a linearity test. In the first case study, GAMs strongly out‐performed GLMs as measured by AIC in modeling relative abundance, and GAMs helped uncover nonlinear responses of carnivore species to landscape development. In the second case study, 14% of species‐specific models failed a formal statistical test for linearity. We also found that differences between linear and nonlinear (i.e., those with a transformed independent variable) model predictions were similar for some species but not for others, with implications for inference and conservation decision‐making. Our review suggests that reporting tests for linearity are rare in recent studies employing GLMs. Our case studies show how formally comparing models that allow for nonlinear relationships between the dependent and independent variables has the potential to impact inference, generate new hypotheses, and alter conservation implications. We conclude by suggesting that ecological studies report tests for linearity and use formal methods to address linearity assumption violations in GLMs.
... To examine the impact of longer MCMC chains in achieving convergence, we ran an additional test by taking 400,000 samples excluding 20% burn-in, and then thinning the chain by a factor of 50 for visualisation. Thinning is the process of reducing the memory burden of the chain, particularly where samples may be auto-correlated [131]. We can also use thinning to more easily visualise long chains with many samples. ...
Article
Full-text available
Bayesian inference provides a methodology for parameter estimation and uncertainty quantification in machine learning and deep learning methods. Variational inference and Markov Chain Monte-Carlo (MCMC) sampling methods are used to implement Bayesian inference. In the past three decades, MCMC sampling methods have faced some challenges in being adapted to larger models (such as in deep learning) and big data problems. Advanced proposal distributions that incorporate gradients, such as a Langevin proposal distribution, provide a means to address some of the limitations of MCMC sampling for Bayesian neural networks. Furthermore, MCMC methods have typically been constrained to statisticians and currently not well-known among deep learning researchers. We present a tutorial for MCMC methods that covers simple Bayesian linear and logistic models, and Bayesian neural networks. The aim of this tutorial is to bridge the gap between theory and implementation via coding, given a general sparsity of libraries and tutorials to this end. This tutorial provides code in Python with data and instructions that enable their use and extension. We provide results for some benchmark problems showing the strengths and weaknesses of implementing the respective Bayesian models via MCMC. We highlight the challenges in sampling multi-modal posterior distributions for the case of Bayesian neural networks and the need for further improvement of convergence diagnosis methods.
... We ran four chains for each model, with a warm-up phase of 2000 iterations (analogous to the burn-in phase in other software) and an additional 7000 iterations that were retained for each chain. We did not apply thinning to the posteriors, as computational memory was not a limiting factor for model runs (Link and Eaton 2012;Annis et al. 2017) and estimates of bulk and tail effective sample sizes were sufficiently large (Gelman et al. 2013). Inspection of trace plots for chains and the potential scale reduction factor (r ; Gelman and Rubin 1992) indicated that all parameters converged (i.e., r < 1.10). ...
Article
Full-text available
Objective In 2000, the Laguna Atascosa National Wildlife Refuge acquired the Bahia Grande (Texas) management unit, a space that had lain barren and arid for 70 years. A large cooperative partnership launched a restoration project to replenish the basin and recover its original tidal hydrology. In 2005, the construction of a pilot channel successfully restored water throughout the basin, and plans to eventually widen the channel were developed. Our study aims to evaluate an estuarine habitat restoration by assessing ecological drivers and the impacts on species diversity. Methods We evaluated species richness, detection/occupancy rates, and species–habitat relationships, and we estimated the sampling effort required to achieve a given level of relative precision if relative abundance was used instead of occupancy to inform future sampling. Sampling gear included bag seines for juvenile life stages and gill nets for capturing subadult and adult life stages. For analysis, we used a Bayesian negative binomial linear mixed‐effects model to evaluate richness–habitat relationships and a hierarchical Bayesian multispecies model to evaluate individual species–habitat relationships, and we calculated the total number of fish captured and relative standard error by gear and sample year to produce a precise estimate of relative abundance. Result Overall, 29 species were caught between 2018 and 2021. Salinity emerged as a clear driver in the Bahia Grande, as both species richness and individual‐level responses were negatively associated with high salinity values. We found that catch estimated as relative abundance had much variability, as is typical of most survey programs assuming constant detectability, and the number of net sets or seine hauls required to achieve a given level of relative precision varied considerably depending on the species, season, year, and gear type. The most collected species were found in the upper extremes of their salinity tolerances—potentially a unique adaptation to this hypersaline system. Conclusion Baseline data suggest that for the channel widening to be successful, there must be a noticeable increase in suitable habitat characteristics throughout the basin.
... Rights reserved. Geyer (1992), and Link and Eaton (2012) have shown that it is neither necessary nor desirable to approximate simple characteristics of the posterior distribution, such as means, variances, and percentiles. ...
Article
Full-text available
Longitudinal studies have been conducted in various fields, including medicine, economics and the social sciences. In this paper, we focus on longitudinal ordinal data. Since the longitudinal data are collected over time, repeated outcomes within each subject may be serially correlated. To address both the within-subjects serial correlation and the specific variance between subjects, we propose a Bayesian cumulative probit random effects model for the analysis of longitudinal ordinal data. The hypersphere decomposition approach is employed to overcome the positive definiteness constraint and high-dimensionality of the correlation matrix. Additionally, we present a hybrid Gibbs/Metropolis-Hastings algorithm to efficiently generate cutoff points from truncated normal distributions, thereby expediting the convergence of the Markov Chain Monte Carlo (MCMC) algorithm. The performance and robustness of our proposed methodology under misspecified correlation matrices are demonstrated through simulation studies under complete data, missing completely at random (MCAR), and missing at random (MAR). We apply the proposed approach to analyze two sets of actual ordinal data: the arthritis dataset and the lung cancer dataset. To facilitate the implementation of our method, we have developed BayesRGMM, an open-source R package available on CRAN, accompanied by comprehensive documentation and source code accessible at https://github.com/kuojunglee/BayesRGMM/.
... All Bayesian models were fit using JAGS (Plummer 2003) and the R2Jags package (Su and Yajima 2021), using three chains with 12,000 iterations each and 3,000 burn-in iterations, for a total for 27,000 samples of the joint posterior distribution. After burn-in, we retained all samples in the chains because thinning would likely reduce the precision of our parameter estimates (Link and Eaton 2012). ...
Article
Full-text available
Context Artificial light at night (ALAN) is increasing worldwide, with many ecological effects. Aerial insectivores may benefit from foraging on insects congregating at light sources. However, ALAN could negatively impact them by increasing nest visibility and predation risk, especially for ground-nesting species like nightjars (Caprimulgidae). Objectives We tested predictions based on these two alternative hypotheses, potential foraging benefits vs potential predation costs of ALAN, for two nightjar species in British Columbia: Common Nighthawks (Chordeiles minor) and Common Poorwills (Phalaenoptilus nuttallii). Methods We modeled the relationship between ALAN and relative abundance using count data from the Canadian Nightjar Survey. We distinguished territorial from extra-territorial Common Nighthawks based on their wingboom behaviour. Results We found limited support for the foraging benefit hypothesis: there was an increase in relative abundance of extra-territorial Common Nighthawks in areas with higher ALAN but only in areas with little to no urban land cover. Common Nighthawks’ association with ALAN became negative in areas with 18% or more urban land cover. We found support for the nest predation hypothesis: the were strong negative associations with ALAN for both Common Poorwills and territorial Common Nighthawks. Conclusions The positive effects of ALAN on foraging nightjars may be limited to species that can forage outside their nesting territory and to non-urban areas, while the negative effects of ALAN on nesting nightjars may persist across species and landscape contexts. Reducing light pollution in breeding habitat may be important for nightjars and other bird species that nest on the ground.
... For each analysis, we ran an adaptation phase of up to 10,000 iterations decided automatically by JAGS, and then discarded samples as burn-in until Gelman-Rubin convergence diagnostic (R-hat) was <1.01 and the number of effective samples was estimated to be >4000 for all parameters, except for the standard deviation parameters of the random effects. We did not thin the MCMC posteriors (Link & Eaton, 2012). We tested the model goodness of fit using a Bayesian p-value approach that compared the fit of the observed data to the equivalent fit of data simulated under the model with estimated parameters (Kéry & Royle, 2015). ...
Article
Full-text available
Single‐visit surveys of plots are often used for estimating the abundance of species of conservation concern. Less‐than‐perfect availability and detection of individuals can bias estimates if not properly accounted for. We developed field methods and a Bayesian model that accounts for availability and detection bias during single‐visit visual plot surveys. We used simulated data to test the accuracy of the method under a realistic range of generating parameters and applied the method to Florida's east coast diamondback terrapin in the Indian River Lagoon system, where they were formerly common but have declined in recent decades. Simulations demonstrated that the method produces unbiased abundance estimates under a wide range of conditions that can be expected to occur in such surveys. Using terrapins as an example we show how to include covariates and random effects to improve estimates and learn about species‐habitat relationships. Our method requires only counting individuals during short replicate surveys rather than keeping track of individual identity and is simple to implement in a variety of point count settings when individuals may be temporarily unavailable for observation. We provide examples in R and JAGS for implementing the model and to simulate and evaluate data to validate the application of the method under other study conditions.
... Mplus automatically discards the first half of the samples as burnin (Asparouhov & Muthén, 2010). We did not use thinning (Link & Eaton, 2011). We visually assessed the trace plots for the convergence of the 2 MCMC chains (Song & Lee, 2012). ...
Article
Full-text available
Interactions between law enforcement agents in conservation (e.g., rangers) and illegal resource users (e.g., illegal hunters) can be violent and sometimes fatal, which negatively affects conservation efforts and people's well‐being. Models from social psychology, such as integrated threat theory (ITT) (intergroup interactions shape intergroup emotions, prejudices and perceived threats leading to hostile attitudes or behaviors between groups), are useful in addressing such interactions. Conservation approaches relying mainly on law enforcement have never been investigated using this framework. Using a structured questionnaire, we collected data from 282 rangers in protected and unprotected areas (n = 50) in northern Iran. We applied Bayesian structural equation modeling in an assessment of rangers’ affective attitudes (i.e., emotions or feelings that shape attitudes toward a person or object) toward illegal hunters in an ITT framework. Rangers’ positive perceptions of illegal hunters were negatively associated with intergroup anxiety (emotional response to fear) and negative stereotypes about a hunter's personality, which mediated the relationship between negative contact and affective attitudes. This suggests that negative contact, such as verbal abuse, may lead rangers to perceive illegal hunters as arrogant or cruel, which likely forms a basis for perceived threats. Rangers’ positive contact with illegal hunters, such as playing or working together, likely lowered their perceived realistic threats (i.e., fear of property damage). Perceived realistic threats of rangers were positively associated with negative contacts (e.g., physical harm). The associations we identified suggest that relationships based on positive interactions between rangers and illegal hunters can reduce fear and prejudice. Thus, we suggest that rangers and hunters be provided with safe spaces to have positive interactions, which may help lower tension and develop cooperative conservation mechanisms.
... To detect differences in the variances of the chains, and other problems whichR is known to miss, we also used folded-R and rank-normalised-R (Vehtari, Gelman, Simpson, Carpenter, & Bürkner, 2021). We reduced the memory cost by thinning the chain, using only every 50th sample (we did this purely for memory reasons, not because it is necessary for MCMC algorithms (Link & Eaton, 2012)). For a first pass, we sought to discard chains which differed substantially from other chains in the explored region in parameter space, either because they never reached the relevant parts of it, or because they spent disproportionate amounts of time in some modes over others. ...
Preprint
Full-text available
Learning to exploit the contingencies of a complex experiment is not an easy task for animals. Individuals learn in an idiosyncratic manner, revising their approaches multiple times as they are shaped, or shape themselves, and potentially end up with different strategies. Their long-run learning curves are therefore a tantalizing target for the sort of individualized quantitative characterizations that sophisticated modelling can provide. However, any such model requires a flexible and extensible structure which can capture radically new behaviours as well as slow changes in existing ones. To this end, we suggest a dynamic input-output infinite hidden semi-Markov model, whose latent states are associated with specific components of behaviour. This model includes an infinite number of potential states and so has the capacity to describe substantially new behaviours by unearthing extra states; while dynamics in the model allow it to capture more modest adaptations to existing behaviours. We individually fit the model to data collected from more than 100 mice as they learned a contrast detection task over tens of sessions and around fifteen thousand trials each. Despite large individual differences, we found that most animals progressed through three major stages of learning, the transitions between which were marked by distinct additions to task understanding. We furthermore showed that marked changes in behaviour are much more likely to occur at the very beginning of sessions, i.e. after a period of rest, and that response biases in earlier stages are not predictive of biases later on in this task.
... As a general rule of thumb, I suggest using weakly regularizing priors when estimating CRN models, to reduce the risk of inferential bias while promoting more efficient model convergence (Lemoine, 2019;McElreath, 2020). Finally, note that despite it still being common to see thinning of MCMC chains reported in the literature, this practice is unnecessary and computationally inefficient (Link & Eaton, 2011). ...
Preprint
Full-text available
Estimating quantitative genetic and phenotypic (co)variances plays a crucial role in investigating key evolutionary ecological phenomena, such as developmental integration, life history tradeoffs, and niche specialization, as well as in describing selection and predicting multivariate evolution in the wild. While most studies assume (co)variances are fixed over short timescales, environmental heterogeneity can rapidly modify the variation of and associations among functional traits. Here I introduce a covariance reaction norm (CRN) model designed to address the challenge of detecting how trait (co)variances respond to continuous environmental change, building on the animal model used for quantitative genetic analysis in the wild. CRNs predict (co)variances as a function of continuous and/or discrete environmental factors, using the same multilevel modeling approach taken to prediction of trait means in standard analyses. After formally introducing the CRN model, I validate its implementation in Stan, demonstrating unbiased Bayesian inference. I then illustrate its application using long-term data on cooperation in meerkats (Suricata suricatta), finding that genetic (co)variances between social behaviors change as a function of group size, as well as in response to age, sex, and dominance status. Accompanying R code and a tutorial are provided to aid empiricists in applying CRN models to their own datasets.
... We used the simulation of 3 chains for 150,000 iterations, with the first 75,000 used as burn-in and sampling every 375 iterations. The thinning of MCMC chains was applied due to memory and computation limitations (Link & Eaton, 2012). Thus, we saved 200 iterations per ...
Article
Full-text available
Aim Australian woodlands have been intensively cleared since European settlement and, in parallel, many species of birds inhabiting this habitat type have experienced a marked decline. Conversely, some species such as noisy miner Manorina melanocephala respond positively to habitat disturbance and due to their hyper‐aggressiveness can end up driving away specialized and fragmentation‐sensitive species. Recent studies have suggested that the negative impact of miners is exacerbated by means of synergistic interactions between these and other aggressive species, including nest predators. However, it is not clear if these positive associations arise through similar habitat requirements or due to potential mutual benefits (‘facilitation effects’), which should predominate in harsh environments as the stress‐gradient hypothesis (SGH) predicts. Location Eastern Australia. Methods We combined a multi‐season community N‐mixture model and joint species distribution models within the Hierarchical Modelling of Species Communities framework to examine species co‐occurrence patterns after accounting for imperfect detection and the influence of environmental variables. We then explored how the balance between positive and negative associations varied along an abiotic stress gradient and whether species‐to‐species associations were non‐randomly distributed with respect to species traits. Results No significant associations were detected; we only found tentative associations (posterior probability 85%) in a low proportion of species pairs (~4%). Although most non‐random (tentative) associations were negative, these were weaker and less consistent across models than the positive ones. Five medium‐sized species of swooping birds including the noisy miner monopolized virtually all positive associations. Communities from low‐productivity environments tended to show a lower degree of overall (community‐level) competitiveness than those located in less stressful (more productive) environments, which supports the SGH. There was no significant relationship between species trait dissimilarity and species‐to‐species association's strength. Main Conclusions Our results suggest that aggressive species like miners, kookaburras, lorikeets, magpies and butcherbirds can form potential synergies with each other that may intensify the direct negative influence of each species on small‐sized songbirds. Since these species thrive in anthropized landscapes and have drastically increased their numbers in some regions, their associative potential should be considered in conservation actions.
... If multiple chains are run with our macro based on PROC MCMC, a two-step check is performed by first checking each chain separately and then checking whether the whole sampling process (consisting of multiple chains) has converged. However, it has been argued that besides a PSR that is close to 1, another condition should ideally be met before model estimates are computed from the chain(s): the number of independent draws from the posterior (i.e., the effective sample size; ESS) should be large [6,8,22]. Based on their simulations, Zitzmann and Hecht [6] suggested an ESS of at least 400 and ideally 1000 independent draws. ...
Article
Full-text available
A crucial challenge in Bayesian modeling using Markov chain Monte Carlo (MCMC) estimation is to diagnose the convergence of the chains so that the draws can be expected to closely approximate the posterior distribution on which inference is based. A close approximation guarantees that the MCMC error exhibits only a negligible impact on model estimates and inferences. However, determining whether convergence has been achieved can often be challenging and cumbersome when relying solely on inspecting the trace plots of the chain(s) or manually checking the stopping criteria. In this article, we present a SAS macro called %automcmc that is based on PROC MCMC and that automatically continues to add draws until a user-specified stopping criterion (i.e., a certain potential scale reduction and/or a certain effective sample size) is reached for the chain(s).
Preprint
Exoplanet research is carried out at the limits of the capabilities of current telescopes and instruments. The studied signals are weak, and often embedded in complex systematics from instrumental, telluric, and astrophysical sources. Combining repeated observations of periodic events, simultaneous observations with multiple telescopes, different observation techniques, and existing information from theory and prior research can help to disentangle the systematics from the planetary signals, and offers synergistic advantages over analysing observations separately. Bayesian inference provides a self-consistent statistical framework that addresses both the necessity for complex systematics models, and the need to combine prior information and heterogeneous observations. This chapter offers a brief introduction to Bayesian inference in the context of exoplanet research, with focus on time series analysis, and finishes with an overview of a set of freely available programming libraries.
Chapter
Populations, collections of interacting organisms of the same species, have a variety of interesting structures. For example, populations contain individuals of different ages (newborn, 1-, 2-year-old, and so on) and sexes (male and female), and thus have age-sex structures. Another universal and fascinating characteristic of populations, which will be the focus of this book, is that they have spatial structures, meaning that we can always find more or fewer individuals in some areas than in other areas, while sometimes we find none at all. On top of that, such spatial structures are dynamic, meaning that they change over time (e.g., an area with none of a species in a year may have a few individuals of that species in the next year). The processes underlying spatially structured population dynamics are called BIDE, which stands for birth, immigration, death, and emigration (Bartlett 1960; Pulliam 1988; Thomas and Kunin 1999). While birth and immigration make populations increase, death and emigration make them decrease. Furthermore, immigration and emigration are linked, in the sense that immigrants in an area must be emigrants from some other areas. The BIDE process is also called demography, while immigration and emigration combined can be called dispersal movement, or simply movement. Spatially structured population dynamics and underlying BIDE processes are driven by heterogeneity and dynamics of abiotic environment, along with intra- and inter-specific interactions.
Article
Seasonal autoregressive (SAR) time series models have been extended to fit time series exhibiting multiple seasonalities. However, hardly any research in Bayesian literature has been done on modelling multiple seasonalities. In this article, we propose a full Bayesian analysis of triple SAR (TSAR) models for time series with triple seasonality, considering identification, estimation and prediction for these TSAR models. In this Bayesian analysis of TSAR models, we assume the model errors to be normally distributed and the model order to be a random variable with a known maximum value, and we employ the g prior for the model coefficients and variance. Accordingly, we first derive the posterior mass function of the TSAR order in closed form, which then enables us to identify the best order of TSAR model as the order value with the highest posterior probability. In addition, we derive the conditional posteriors to be a multivariate normal for the TSAR coefficients and to be an inverse gamma for the TSAR variance; also, we derive the conditional predictive distribution to be a multivariate normal for future observations. Since these derived conditional distributions are in closed forms, we introduce the Gibbs sampler to present the Bayesian analysis of TSAR models and to easily produce multiple‐step‐ahead predictions. Using Julia programming language, we conduct an extensive simulation study, aiming to evaluate the accuracy of our proposed full Bayesian analysis for TSAR models. In addition, we apply our work on time series to hourly electricity load in some European countries.
Article
The G-20 countries represent a considerable percentage of the global economy and are crucial in matters to do with support for environmental sustainability. The uniqueness of this study lies in determining the effects of forests on human welfare and environmental degradation with respect to G20, offering a unique perspective regarding the efforts to battle climate change. The study analyzed the impact of income, forest extent and education on ecological and carbon intensity of wellbeing following the Environmental Kuznets Curve (EKC) hypothesis. Based on annual data from 1990 to 2022 and employing the Moment Quantile Regression Method, the results validate the presence of an inverted U-Shaped relationship between GDP and environmental well-being which refers to the existence of EKC. Our results connect enhanced ecological and carbon intensity well-being with expanding forest coverage and improving education levels. Forest management combined with educational management work as an effective mechanism reducing environmental degradation while also positively contributing to human welfare. In addition, through these informed and rational decisions, policy makers can promote the environmental stability of forests.
Article
Background Clinical trials are increasingly using Bayesian methods for their design and analysis. Inference in Bayesian trials typically uses simulation-based approaches such as Markov Chain Monte Carlo methods. Markov Chain Monte Carlo has high computational cost and can be complex to implement. The Integrated Nested Laplace Approximations algorithm provides approximate Bayesian inference without the need for computationally complex simulations, making it more efficient than Markov Chain Monte Carlo. The practical properties of Integrated Nested Laplace Approximations compared to Markov Chain Monte Carlo have not been considered for clinical trials. Using data from a published clinical trial, we aim to investigate whether Integrated Nested Laplace Approximations is a feasible and accurate alternative to Markov Chain Monte Carlo and provide practical guidance for trialists interested in Bayesian trial design. Methods Data from an international Bayesian multi-platform adaptive trial that compared therapeutic-dose anticoagulation with heparin to usual care in non-critically ill patients hospitalized for COVID-19 were used to fit Bayesian hierarchical generalized mixed models. Integrated Nested Laplace Approximations was compared to two Markov Chain Monte Carlo algorithms, implemented in the software JAGS and stan, using packages available in the statistical software R. Seven outcomes were analysed: organ-support free days (an ordinal outcome), five binary outcomes related to survival and length of hospital stay, and a time-to-event outcome. The posterior distributions for the treatment and sex effects and the variances for the hierarchical effects of age, site and time period were obtained. We summarized these posteriors by calculating the mean, standard deviations and the 95% equitailed credible intervals and presenting the results graphically. The computation time for each algorithm was recorded. Results The average overlap of the 95% credible interval for the treatment and sex effects estimated using Integrated Nested Laplace Approximations was 96% and 97.6% compared with stan, respectively. The graphical posterior densities for these effects overlapped for all three algorithms. The posterior mean for the variance of the hierarchical effects of age, site and time estimated using Integrated Nested Laplace Approximations are within the 95% credible interval estimated using Markov Chain Monte Carlo but the average overlap of the credible interval is lower, 77%, 85.6% and 91.3%, respectively, for Integrated Nested Laplace Approximations compared to stan. Integrated Nested Laplace Approximations and stan were easily implemented in clear, well-established packages in R, while JAGS required the direct specification of the model. Integrated Nested Laplace Approximations was between 85 and 269 times faster than stan and 26 and 1852 times faster than JAGS. Conclusion Integrated Nested Laplace Approximations could reduce the computational complexity of Bayesian analysis in clinical trials as it is easy to implement in R, substantially faster than Markov Chain Monte Carlo methods implemented in JAGS and stan, and provides near identical approximations to the posterior distributions for the treatment effect. Integrated Nested Laplace Approximations was less accurate when estimating the posterior distribution for the variance of hierarchical effects, particularly for the proportional odds model, and future work should determine if the Integrated Nested Laplace Approximations algorithm can be adjusted to improve this estimation.
Article
Full-text available
Instagram is currently the third most popular social network used by Indian college students. This study draws a parallel between Indian and American-origin comics on Instagram to study the new age pop culture art in the two countries. The research was conducted by reviewing the content based on the parameters like several followers, likes, comments, and analyzing the content being generated in the two cultures by studying the type of characters, issues raised, and the primary color palette used. Content analysis using machine learning was used as the method for the research. The content is generated in India and the US. Virtual Comic culture in America seems to be more popular than the one in India. Indian comic artists take time to make comics on the social issues prevalent in society, contrary to the latter. American comic artists dedicate a significant amount of time drawing about their love life. Indian comic artists like more use of colors than the American ones. Certain similarities include Comics from both the countries, They focus majorly on their issues, that is, the artists draw about their personal lives and their everyday incidents like their difficulty of waking up in the morning, shopping, gaming, their lousy mood days, etc. Female characters tend to take the lead in the case of Instagram comics, which is proof of the changing society. Representation of political issues is almost none in the virtual comics.
Article
The majority of attempts to enumerate the homeless population rely on point-in-time or shelter counts, which can be costly and inaccurate. As an alternative, we use electronic health records from the Vancouver Island Health Authority, British Columbia, Canada from 2013 to 2022 to identify adults contending with homelessness based on their self-reported housing status. We estimate the annual population size of this population using a flexible open-population capture–recapture model that takes into account (1) the age and gender structure of the population, including aging across detection occasions, (2) annual recruitment into the population, (3) behavioural-response, and (4) apparent survival in the population, including emigration and incorporating known deaths. With this model, we demonstrate how to perform model selection for the inclusion of covariates. We then compare our estimates of annual population size with reported point-in-time counts of homeless populations on Vancouver Island over the same time period, and find that using data extracts from electronic health records gives comparable estimates. We find similarly comparable results using only a subset of interaction data, when using only ER interactions, suggesting that even if cross-continuum data is not available, reasonable estimates of population size can still be found using our method.
Article
Full-text available
Item response theory (IRT) has evolved as a standard psychometric approach in recent years, in particular for test construction based on dichotomous (i.e., true/false) items. Unfortunately, large samples are typically needed for item refinement in unidimensional models and even more so in the multidimensional case. However, Bayesian IRT approaches with hierarchical priors have recently been shown to be promising for estimating even complex models in small samples. Still, it may be challenging for applied researchers to set up such IRT models in general purpose or specialized statistical computer programs. Therefore, we developed a user-friendly tool – a SAS macro called HBMIRT – that allows to estimate uni- and multidimensional IRT models with dichotomous items. We explain the capabilities and features of the macro and demonstrate the particular advantages of the implemented hierarchical priors in rather small samples over weakly informative priors and traditional maximum likelihood estimation with the help of a simulation study. The macro can also be used with the online version of SAS OnDemand for Academics that is freely accessible for academic researchers.
Article
Full-text available
As ChatGPT emerges as a potential ally in healthcare decision-making, it is imperative to investigate how users leverage and perceive it. The repurposing of technology is innovative but brings risks, especially since AI’s effectiveness depends on the data it’s fed. In healthcare, ChatGPT might provide sound advice based on current medical knowledge, which could turn into misinformation if its data sources later include erroneous information. Our study assesses user perceptions of ChatGPT, particularly of those who used ChatGPT for healthcare-related queries. By examining factors such as competence, reliability, transparency, trustworthiness, security, and persuasiveness of ChatGPT, the research aimed to understand how users rely on ChatGPT for health-related decision-making. A web-based survey was distributed to U.S. adults using ChatGPT at least once a month. Bayesian Linear Regression was used to understand how much ChatGPT aids in informed decision-making. This analysis was conducted on subsets of respondents, both those who used ChatGPT for healthcare decisions and those who did not. Qualitative data from open-ended questions were analyzed using content analysis, with thematic coding to extract public opinions on urban environmental policies. Six hundred and seven individuals responded to the survey. Respondents were distributed across 306 US cities of which 20 participants were from rural cities. Of all the respondents, 44 used ChatGPT for health-related queries and decision-making. In the healthcare context, the most effective model highlights ’Competent + Trustworthy + ChatGPT for healthcare queries’, underscoring the critical importance of perceived competence and trustworthiness specifically in the realm of healthcare applications of ChatGPT. On the other hand, the non-healthcare context reveals a broader spectrum of influential factors in its best model, which includes ’Trustworthy + Secure + Benefits outweigh risks + Satisfaction + Willing to take decisions + Intent to use + Persuasive’. In conclusion our study findings suggest a clear demarcation in user expectations and requirements from AI systems based on the context of their use. We advocate for a balanced approach where technological advancement and user readiness are harmonized.
Article
During cellular processes such as differentiation or response to external stimuli, cells exhibit dynamic changes in their gene expression profiles. Single-cell RNA sequencing (scRNA-seq) can be used to investigate these dynamic changes. To this end, cells are typically ordered along a pseudotemporal trajectory which recapitulates the progression of cells as they transition from one cell state to another. We infer transcriptional dynamics by modeling the gene expression profiles in pseudotemporally ordered cells using a Bayesian inference approach. This enables ordering genes along transcriptional cascades, estimating differences in the timing of gene expression dynamics, and deducing regulatory gene interactions. Here, we apply this approach to scRNA-seq datasets derived from mouse embryonic forebrain and pancreas samples. This analysis demonstrates the utility of the method to derive the ordering of gene dynamics and regulatory relationships critical for proper cellular differentiation and maturation across a variety of developmental contexts.
Article
When active learning (AL) is applied to help users develop a model on a large dataset through interactively presenting data instances for labeling, existing AL techniques often suffer from two main drawbacks: First, to reach high accuracy they may require the user to label hundreds of data instances, which is an onerous task for the user. Second, retrieving the next instance to label from a large dataset can be time-consuming, making it incompatible with the interactive nature of the human exploration process. To address these issues, we introduce a novel version-space-based active learner for kernel classifiers, which possesses strong theoretical guarantees on performance and efficient implementation in time and space. In addition, by leveraging additional insights obtained in the user labeling process, we can factorize the version space to perform active learning in a set of subspaces, which further reduces the user labeling effort. Evaluation results show that our algorithms significantly outperform state-of-the-art version space strategies, as well as a recent factorization-aware algorithm, for model development over large data sets.
Preprint
Life history tradeoffs are one of the central tenets of evolutionary demography. Tradeoffs, depicting negative phenotypic or genetic covariances between individuals’ demographic rates, arise from a finite amount of resources that each individual has to allocate in a zero-sum game between somatic and reproductive functions. While theory predicts that tradeoffs are ubiquitous, empirical studies have often failed to detect such negative covariances in wild populations. One way to improve the detection of tradeoffs is by accounting for the environmental context, as tradeoff expression may depend on environmental conditions. However, current methodologies usually search for fixed covariances between traits, thereby ignoring their context dependence. Here, we present a hierarchical multivariate ‘covariance reaction norm’ model, adapted to help detect context dependence in the expression of demographic tradeoffs. The method allows continuous variation in the phenotypic correlation between traits. We validate the model on simulated data for both intraindividual and intergenerational tradeoffs. We then apply it to empirical datasets of yellow-bellied marmots (Marmota flaviventer) and Soay sheep (Ovis aries) as a proof-of-concept showing that new insights can be gained by applying our methodology, such as detecting tradeoffs only in specific environments. We discuss its potential for application to many of the existing long-term demographic datasets and how it could improve our understanding of tradeoff expression in particular, and life-history theory in general.
Article
Performance assessments increasingly utilize onscreen or internet-based technology to collect human ratings. One of the benefits of onscreen ratings is the automatic recording of rating times along with the ratings. Considering rating times as an additional data source can provide a more detailed picture of the rating process and improve the psychometric quality of the assessment outcomes. However, currently available models for analyzing performance assessments do not incorporate rating times. The present research aims to fill this gap and advance a joint modeling approach, the “hierarchical facets model for ratings and rating times” (HFM-RT). The model includes two examinee parameters (ability and time intensity) and three rater parameters (severity, centrality, and speed). The HFM-RT successfully recovered examinee and rater parameters in a simulation study and yielded superior reliability indices. A real-data analysis of English essay ratings collected in a high-stakes assessment context revealed that raters exhibited considerably different speed measures, spent more time on high-quality than low-quality essays, and tended to rate essays faster with increasing severity. However, due to the significant heterogeneity of examinees’ writing proficiency, the improvement in the assessment’s reliability using the HFM-RT was not salient in the real-data example. The discussion focuses on the advantages of accounting for rating times as a source of information in rating quality studies and highlights perspectives from the HFM-RT for future research on rater cognition.
Article
Full-text available
Juvenile survival in birds is difficult to estimate, but this vital rate can be an important consideration for management decisions. We estimated juvenile survival of cooperatively breeding Florida Scrub-Jays (Aphelocoma coerulescens) in a landscape degraded by fire suppression and fragmentation using data from marked (n = 325) and unmarked juveniles (n = 1,306) with an integrated hierarchical Bayesian model. To assess the combined analyses, we also analyzed these datasets separately, with a Cormack–Jolly–Seber model (marked) and young model (unmarked). Our data consisted of monthly censuses of territorial family groups from Florida Scrub-Jay populations in East Central Florida collected over a 22-year period. Juvenile survival was estimated from July when young Florida Scrub-Jays begin developing independence to March when they become first-year individuals and grouped according to the habitat quality class of their natal territory that were based on shrub height (with intermediate shrub heights being optimal and short and tall shrub heights being suboptimal) and the presence of sandy openings (the preferred open having many sandy openings; closed not having enough). Parameter estimates in the combined analysis were intermediate to the separate analyses. Notable differences among the separate analyses were that suboptimal habitat survival was lower in the unmarked analysis, the unmarked analysis showed a linear effect of time not seen in the marked analysis, and there was an effect of male breeder death in the marked but not unmarked analysis. The combined data analysis provided more inference than did either dataset analyzed separately including juveniles in optimal-closed territories unexpectedly had higher survival than those in optimal-open, survival increased through time, and male breeder death had a negative effect on survival. This study suggests that optimal-closed habitat may play an important role in juvenile Florida Scrub-Jay survival perhaps by providing better cover from predators and warrants further investigation for management implications.
Article
Full-text available
We generalize the method proposed by Gelman and Rubin (1992a) for monitoring the convergence of iterative simulations by comparing between and within variances of multiple chains, in order to obtain a family of tests for convergence. We review methods of inference from simulations in order to develop convergence-monitoring summaries that are relevant for the purposes for which the simulations are used. We recommend applying a battery of tests for mixing based on the comparison of inferences from individual sequences and from the mixture of sequences. Finally, we discuss multivariate analogues, for assessing convergence of several parameters simultaneously.
Article
Full-text available
Current reporting of results based on Markov chain Monte Carlo computations could be improved. In particular, a measure of the accuracy of the resulting estimates is rarely reported. Thus we have little ability to objectively assess the quality of the reported estimates. We address this issue in that we discuss why Monte Carlo standard errors are important, how they can be easily calculated in Markov chain Monte Carlo and how they can be used to decide when to stop the simulation. We compare their use to a popular alternative in the context of two examples. Comment: Published in at http://dx.doi.org/10.1214/08-STS257 the Statistical Science (http://www.imstat.org/sts/) by the Institute of Mathematical Statistics (http://www.imstat.org)
Article
Estimating the age of individuals in wild populations can be of fundamental importance for answering ecological questions, modeling population demographics, and managing exploited or threatened species. Significant effort has been devoted to determining age through the use of growth annuli, secondary physical characteristics related to age, and growth models. Many species, however, either do not exhibit physical characteristics useful for independent age validation or are too rare to justify sacrificing a large number of individuals to establish the relationship between size and age. Length-at-age models are well represented in the fisheries and other wildlife management literature. Many of these models overlook variation in growth rates of individuals and consider growth parameters as population parameters. More recent models have taken advantage of hierarchical structuring of parameters and Bayesian inference methods to allow for variation among individuals as functions of environmental covariates or individual-specific random effects. Here, we describe hierarchical models in which growth curves vary as individual-specific stochastic processes, and we show how these models can be fit using capture-recapture data for animals of unknown age along with data for animals of known age. We combine these independent data sources in a Bayesian analysis, distinguishing natural variation (among and within individuals) from measurement error. We illustrate using data for African dwarf crocodiles, comparing von Bertalanffy and logistic growth models. The analysis provides the means of predicting crocodile age, given a single measurement of head length. The von Bertalanffy was much better supported than the logistic growth model and predicted that dwarf crocodiles grow from 19.4 cm total length at birth to 32.9 cm in the first year and 45.3 cm by the end of their second year. Based on the minimum size of females observed with hatchlings, reproductive maturity was estimated to be at nine years. These size benchmarks are believed to represent thresholds for important demographic parameters; improved estimates of age, therefore, will increase the precision of population projection models. The modeling approach that we present can be applied to other species and offers significant advantages when multiple sources of data are available and traditional aging techniques are not practical.
Article
Markov chain Monte Carlo (MCMC) is a statistical innovation that allows researchers to fit far more complex models to data than is feasible using conventional methods. Despite its widespread use in a variety of scientific fields, MCMC appears to be underutilized in wildlife applications. This may be due to a misconception that MCMC requires the adoption of a subjective Bayesian analysis, or perhaps simply to its lack of familiarity among wildlife researchers. We introduce the basic ideas of MCMC and software BUGS (Bayesian inference using Gibbs sampling), stressing that a simple and satisfactory intuition for MCMC does not require extraordinary mathematical sophistication. We illustrate the use of MCMC with an analysis of the association between latent factors governing individual heterogeneity in breeding and survival rates of kittiwakes (Rissa tridactyla). We conclude with a discussion of the importance of individual heterogeneity for understanding population dynamics and designing management plans.
Article
Demographic matrix models are standard tools for analyzing the dynamics of age- or stage-structured populations. Here, we present a method for estimating the average vital rates that parameterize a demographic matrix using a series of measurements of population size and structure (an "inverse problem" of demographic analysis). We join a deterministic, density-independent demographic matrix model with a stochastic observation model to write a likelihood function for the matrix parameters given the data. Adopting a Bayesian perspective, we combine this likelihood function with prior distributions for the model parameters to produce a joint posterior distribution for the parameters. We use a numerical technique (Markov chain Monte Carlo) to estimate and analyze the posterior distribution, and from this we calculate posterior distributions for functions of the demographic matrix, such as the population multiplication rate, stable stage distribution, and matrix sensitivities. Although measurements of population size and structure rarely contain enough information to estimate all the parameters in a matrix precisely, our analysis sheds light on the information that the data do contain about the vital rates by quantifying the precision of the parameter estimates and the correlations among them. Moreover, we show that matrix functions such as the population multiplication rate and matrix sensitivities can still be estimated precisely despite sizable uncertainty in the estimates of individual parameters, permitting biologically meaningful inference. We illustrate our approach for three populations of pea aphids (Acyrthosiphon pisum).
Article
A Bayesian approach is used to develop a method for fitting a metapopulation model (the incidence function model) to data on habitat patch occupancy, providing esti- mates of the five model parameters. Parameter estimation is carried out using a Markov chain Monte Carlo sampler, and data augmentation is used to include the effect of missing data in the analysis. The Bayesian approach allows us to take into account uncertainty about the parameter estimates when making predictions with the model. We demonstrate the methods of parameter estimation and prediction with simulated data. We first simulated metapopulation dynamics in real habitat patch networks with given parameter values and sampled the simulated data. Parameters were estimated both from full data sets, and from data sets with data for many years treated as missing. These estimates were then used to predict the distribution of time to extinction in modified networks, where patch areas had been reduced so that the real parameter values led to metapopulation extinction within ;30 yr. We were successfully able to fit the model and found that, in some cases, the predictions can be sensitive to one of the parameters.
Article
Reliable indicators of species richness (e.g., particular species), if they can be found, offer potentially significant benefits for management planning. Few efficient and statistically valid methods for identifying potential indicators of species richness currently exist. We used Bayesian-based Poisson modeling to explore whether species richness of butterflies in the Great Basin could be modeled as a function of the occurrence (presence or absence) of certain species of butterflies. We used an extensive data set on the occurrence of butterflies of the Toquima Range (Nevada, USA) to build the models. Poisson models based on the occurrence of five and four indicator species explained 88% and 77% of the deviance of observed species richness of resident and montane-resident butterfly assemblages, respectively. We then developed a test framework, including formally defined "rejection criteria," for validating and refining the models. The sensitivity of the models to inventory intensity (number of years of data) and knowledge about the potential indicators was incorporated into this evaluation phase. We conducted a test of our models by using an existing set of data on butterflies in the neighboring Toiyabe Range. Predicted values of species richness were significantly rank correlated with the observed values. Thus, the models appear to have promise for predicting species richness based on the occurrence of certain taxa.
Article
Many ecological studies require analysis of collections of estimates. For example, population change is routinely estimated for many species from surveys such as the North American Breeding Bird Survey (BBS), and the species are grouped and used in comparative analyses. We developed a hierarchical model for estimation of group attributes from a collection of estimates of population trend. The model uses information from predefined groups of species to provide a context and to supplement data for individual species; summaries of group attributes are improved by statistical methods that simultaneously analyze collections of trend estimates. The model is Bayesian; trends are treated as random variables rather than fixed parameters. We use Markov Chain Monte Carlo (MCMC) methods to fit the model. Standard assessments of population stability cannot distinguish magnitude of trend and statistical significance of trend estimates, but the hierarchical model allows us to legitimately describe the probability that a trend is within given bounds. Thus we define population stability in terms of the probability that the magnitude of population change for a species is less than or equal to a predefined threshold. We applied the model to estimates of trend for 399 species from the BBS to estimate the proportion of species with increasing populations and to identify species with unstable populations. Analyses are presented for the collection of all species and for 12 species groups commonly used in BBS summaries. Overall, we estimated that 49% of species in the BBS have positive trends and 33 species have unstable populations. However, the proportion of species with increasing trends differs among habitat groups, with grassland birds having only 19% of species with positive trend estimates and wetland birds having 68% of species with positive trend estimates.
Article
We generalize the method proposed by Gelman and Rubin (1992a) for monitoring the convergence of iterative simulations by comparing between and within variances of multiple chains, in order to obtain a family of tests for convergence. We review methods of inference from simulations in older to develop convergence-monitoring summaries that are relevant for the purposes for which the simulations are used. We recommend applying a battery of tests for mixing based on the comparison of inferences from individual sequences and from the mixture of sequences. Finally, we discuss multivariate analogues, for assessing convergence of several parameters simultaneously.
Article
The Mauritius kestrel Falco punctatus (Temminck 1823) has recovered from very low numbers. In order to evaluate the severity of the population bottleneck that it experienced, we have developed a method for estimating the productivity of the nests that escaped detection. This method uses ringing records for MCMC estimation of parameters describing the recruitment of adults to the breeding population and the growth in productivity of undiscovered nests. Comparison of the estimates for the two restored populations (eastern and western) showed a far lower proportion of undiscovered nests in the former, as predicted because of widespread use of nestboxes. This served to verify the method of estimation. The estimates show a steady increase in population size, in contrast with field estimates indicating a recent reduction in growth. The results suggest that the alarmingly low estimates of population size in 1974 (two breeding pairs) were accurate, and that few undiscovered nests existed during the bottleneck. The recovery of the population seems to have been initiated by the intensive conservation effort. The most rapid period of population growth coincides with the reintroduction programme. The results imply that the eastern population is much more reliant on intensive management for its future growth.
Article
Estimation of population change from count surveys is complicated by variation in quality of information among sample units, by the need for covariates to accommodate factors that influence detectability of animals, and by multiple geographic scales of interest. We present a hierarchical model for estimation of population change from the North American Breeding Bird Survey. Hierarchical models, in which population parameters at different geographic scales are viewed as random variables, provide a convenient framework for summary of population change among regions, accommodating regional variation in survey quality and a variety of distributional assumptions about observer effects and other nuisance parameters. Markov chain Monte Carlo methods provide a convenient means for fitting these models and also allow for construction of estimates of derived variables such as weighted regional trends and composite yearly population indices. We construct an overdispersed Poisson regression model for estimation of trend and year effects for Cerulean Warblers (Dendroica cerulea), accommodating nuisance covariates for observer and start-up effects, and estimating abundance- and area-weighted annual indices at regional and continent-wide geographic scales. A goodness-of-fit test is also presented for the model. Cerulean Warbers declined at a rate of 3.04% per year over the interval 1966-2000.
Article
Estimating the age of individuals in wild populations can be of fundamental importance for answering ecological questions, modeling population demographics, and managing exploited or threatened species. Significant effort has been devoted to determining age through the use of growth annuli, secondary physical characteristics related to age, and growth models. Many species, however, either do not exhibit physical characteristics useful for independent age validation or are too rare to justify sacrificing a large number of individuals to establish the relationship between size and age. Length-at-age models are well represented in the fisheries and other wildlife management literature. Many of these models overlook variation in growth rates of individuals and consider growth parameters as population parameters. More recent models have taken advantage of hierarchical structuring of parameters and Bayesian inference methods to allow for variation among individuals as functions of environmental covariates or individual-specific random effects. Here, we describe hierarchical models in which growth curves vary as individual-specific stochastic processes, and we show how these models can be fit using capture-recapture data for animals of unknown age along with data for animals of known age. We combine these independent data sources in a Bayesian analysis, distinguishing natural variation (among and within individuals) from measurement error. We illustrate using data for African dwarf crocodiles, comparing von Bertalanffy and logistic growth models. The analysis provides the means of predicting crocodile age, given a single measurement of head length. The von Bertalanffy was much better supported than the logistic growth model and predicted that dwarf crocodiles grow from 19.4 cm total length at birth to 32.9 cm in the first year and 45.3 cm by the end of their second year. Based on the minimum size of females observed with hatchlings, reproductive maturity was estimated to be at nine years. These size benchmarks are believed to represent thresholds for important demographic parameters; improved estimates of age, therefore, will increase the precision of population projection models. The modeling approach that we present can be applied to other species and offers significant advantages when multiple sources of data are available and traditional aging techniques are not practical.
Article
Markov chain Monte Carlo using the Metropolis-Hastings algorithm is a general method for the simulation of stochastic processes having probability densities known up to a constant of proportionality. Despite recent advances in its theory, the practice has remained controversial. This article makes the case for basing all inference on one long run of the Markov chain and estimating the Monte Carlo error by standard nonparametric methods well-known in the time-series and operations research literature. In passing it touches on the Kipnis-Varadhan central limit theorem for reversible Markov chains, on some new variance estimators, on judging the relative efficiency of competing Monte Carlo schemes, on methods for constructing more rapidly mixing Markov chains and on diagnostics for Markov chain Monte Carlo.
Article
Statistical thinking in wildlife biology and ecology has been profoundly influenced by the introduction of AIC (Akaike's information criterion) as a tool for model selection and as a basis for model averaging. In this paper, we advocate the Bayesian paradigm as a broader framework for multimodel inference, one in which model averaging and model selection are naturally linked, and in which the performance of AIC-based tools is naturally evaluated. Prior model weights implicitly associated with the use of AIC are seen to highly favor complex models: in some cases, all but the most highly parameterized models in the model set are virtually ignored a priori. We suggest the usefulness of the weighted BIC (Bayesian information criterion) as a computationally simple alternative to AIC, based on explicit selection of prior model probabilities rather than acceptance of default priors associated with AIC. We note, however, that both procedures are only approximate to the use of exact Bayes factors. We discuss and illustrate technical difficulties associated with Bayes factors, and suggest approaches to avoiding these difficulties in the context of model selection for a logistic regression. Our example highlights the predisposition of AIC weighting to favor complex models and suggests a need for caution in using the BIC for computing approximate posterior model weights.
Article
INTRODUCTION Markov chain Monte Carlo methods have enjoyed a surge of interest since Gelfand and Smith (1990) described the Gibbs sampler and its effectiveness in providing approximate Bayesian solutions for models that had previously been approachable only with great difficulty, or that had been discarded as being too difficult to work with. Ongoing research in this area includes widening the applications to ever more detailed and difficult problems, alteration and improvement of the algorithm, and improvement of estimates based on the Markov chain. See Besag and Green (1993) and Smith and Roberts (1993). One of the extraordinary features of the Gibbs sampler is that the theory behind it can be presented at an elementary level (Casella and George, 1992), giving upper level undergraduate or beginning graduate students a glimpse Steve MacEachern is Assistant Professor, Department of Statistics, Ohio State University, and Visiting Assistant Professor, Institute of Stati
Bayesian Inference: With Ecological Applications
  • W A Link
  • R J Barker
Link, W.A. & Barker, R.J. (2010) Bayesian Inference: With Ecological Applications. Elsevier ⁄ Academic Press, Amsterdam.
Subsampling the Gibbs sampler. The American Statistician
  • S N Maceachern
  • L M Berliner