Population closure and the bias‐precision trade‐off in spatial capture–recapture

Spatial capture–recapture (SCR) is an increasingly popular method for estimating ecological parameters. SCR often relies on data collected over relatively long sampling periods. While longer sampling periods can yield larger sample sizes and thus increase the precision of estimates, they also increase the risk of violating the closure assumption, thereby potentially introducing bias. The sampling period characteristics are therefore likely to play an important role in this bias‐precision trade‐off. Yet few studies have studied this trade‐off and none has done so for SCR models. In this study, we explored the influence of the length and timing of the sampling period on the bias‐precision trade‐off of SCR population size estimators. Using a continuous time‐to‐event approach, we simulated populations with a wide range of life histories and sampling periods before quantifying the bias and precision of population size estimates returned by SCR models. While longer sampling periods benefit the study of slow‐living species (increased precision and lower bias), they lead to pronounced overestimation of population size for fast‐living species. In addition, we show that both bias and uncertainty increase when the sampling period overlaps the reproductive season of the study species. Based on our findings, we encourage investigators to carefully consider the life history of their study species when contemplating the length and the timing of the sampling period. We argue that both spatial and non‐spatial capture–recapture studies can safely extend the sampling period to increase precision, as long as it is timed to avoid peak recruitment periods. The simulation framework we propose here can be used to guide decisions regarding the sampling period for a specific situation.

monitored locations (Efford, 2014). SCR models allow estimation of the latent locations of individuals, usually defined by their home range or activity centre (Royle, Chandler, Sollmann, & Gardner, 2013), in addition to the individual latent states usually modelled in non-spatial capture-recapture (CR) models (Gimenez et al., 2007) (e.g. alive/dead for the most classic Cormack-Jolly-Seber model).
This joint modelling of individual locations and states makes SCR particularly fit to analyse data collected using non-invasive monitoring methods, such as camera trapping (Royle, 2011) or non-invasive genetic sampling (NGS: Lukacs & Burnham, 2005), and explains why investigators studying wide-ranging, elusive or rare species have embraced SCR methods (Blanc, Marboutin, Gatti, & Gimenez, 2013;Sollmann et al., 2011).
Despite constant improvements in both monitoring (Harris, Thompson, Childs, & Sanderson, 2010;Lampa, Henle, Klenke, Hoehn, & Gruber, 2013;O'Connell, Nichols, & Karanth, 2010;Roon, Waits, & Kendall, 2005) and analytical methods (Muneza et al., 2017;Royle, Fuller, & Sutherland, 2017;Royle et al., 2013), studying rare and elusive species still requires considerable effort and investment by practitioners to collect sufficient data. Sparse data, that is, when the detected proportion of the population is low, lead to imprecise estimates (Otis, Burnham, White, & Anderson, 1978). This is a particularly salient issue for SCR analyses, as they require multiple detections of the same individuals at different locations in order to be able to estimate the location of latent activity centres. Lengthening the period during which data are collected (the sampling period hereafter) is one common way to increase the size of the dataset, thereby On the other hand, extending the sampling period may lead to potential violations of the population closure assumption, fundamental to both spatial and non-spatial CR methods (Lebreton, Burnham, Clobert, & Anderson, 1992;Royle et al., 2013). This assumption is rarely, if ever, met in practice as some individuals may die/emigrate or new individuals are born/immigrate during the sampling period, which in turn, may change both population size and composition. Population size estimates obtained under these circumstances no longer reflect the state of the population at a given point in time, but rather a composite estimate based on the cumulative number of individuals present during the entire duration of the sampling period (Otis et al., 1978). This measure then becomes challenging to use for researchers interested in the biology of the species under study or for managers interested in population status. Most importantly, management or conservation decisions based on flawed inference may miss their goal (e.g. hunting quotas based on such "cumulative population size" might lead to overhunting).
Following this, we expect to find an optimal sampling period that balances bias and precision of estimates for a given population and monitoring setting. Previous studies that investigated this long-known limitation in the context of classical CR methods failed to detect such bias-precision trade-off and concluded instead that they were very robust to population closure violations, thus advocating for longer sampling periods to maximize the precision of estimates (Hargrove & Borland, 1994;Kendall, 1999;O'Brien, Robert, & Tiandry, 2005;Otis et al., 1978;Rota, Fletcher, Dorazio, & Betts, 2009). However, these studies only explored specific cases, such as random temporary emigration (Kendall, 1999), constant mortality rates without recruitment (O'Brien et al., 2005), or stable populations that is, when recruitment exactly counter-balances mortality (Hargrove & Borland, 1994), thus ignoring realistic scenarios where unbalanced entries and departures into/from the population might occur during sampling.
Similar to the probability to detect an individual, the probability for any given individual to leave the population (through mortality or emigration) and the probability for any new individual to enter the population (through reproduction or immigration) both increase with time. Continuous time-to-event models, which model the time until an event of interest occurs (e.g. death of a patient, failure of an engine; Klein & Moeschberger, 2005), that is the rate at which this event occurs, are well-suited to capture these processes. The rates at which individuals enter and depart from the population determine the extent to which a given dataset violates the population closure assumption and likely affect the potential trade-off between SCR estimators' bias and precision. We therefore expect the effect of sampling period duration on population size estimates returned by SCR models, as well as classical CR models, to depend on the lifehistory strategy of the species under study (Stearns, 1992). Finally, in many taxa, both recruitment and mortality vary throughout the year (Anderson, Rhodes, & Kator, 1983;Brockman & Schaik, 2005;Gauthier, Pradel, Menu, & Lebreton, 2001). Hence, the severity of the population closure violations is also expected to vary based on the timing of the sampling period relative to the recruitment and mortality schedules of the species considered.
The aim of this study was to quantify the consequences of violating the closure assumption for population size estimates obtained using SCR methods. Using simulations, we evaluated: (a) the consequences of extending the sampling period on population size estimates for different life histories and sampling intensities, and (b) the influence of the timing of the sampling period relative to peaks in mortality and recruitment under the same life-history scenarios.
With this study, we provide practitioners with guidelines and an approach for defining an adequate sampling period for SCR studies that minimizes bias caused by the violation of the closure assumption whilst maximizing the precision of estimates.

| Time-to-event simulations
The length and timing of the sampling period are likely to determine the amount of information in the dataset as it influences the detectability of individuals in the population (e.g. Bischof et al., 2014).
Both the probability for an individual to leave the population via death or emigration and the probability to enter the population via recruitment or immigration (i.e. the biological processes) increase with time. In addition, the probability to detect an individual given that it is alive and present in the population (i.e. the detection process) also increases with time. In other words, the probability for an individual to be detected and enter the dataset is the result of a hierarchical time-to-event process (Klein & Moeschberger, 2005) whereby the biological processes determine the time an individual was alive and/or present in the population, which in turn conditions its detectability (Figure 1). This perspective differs from the usual way of simulating CR datasets, where the state of an individual is first modelled and then a single detection probability is applied to all individuals in a particular state (Kery & Schaub, 2011, Supporting Information 3). Using this set-up, both demographic and detection processes are instantaneous and the simulation process matches the model structure exactly. Such simulations are useful for testing a model, but their lack of realism limits our ability to draw inferences about the effect of closure violations in real-life situations (but see Bischof et al., 2014or Ergon & Gardner, 2014 for a consideration of time-dependent detection probabilities).
In an effort to better capture the true processes in our simulations, we used three distinct functions: (a) a survival function S(t) describing the probability for an individual to survive/not emigrate until time t, (b) a reproduction function R(t) describing the probability for an individual to be recruited/immigrate before time t, and (c) a detection function P(t) describing the probability for an individual to be detected before time t. Each of these time-to-event functions X(t) is associated with a hazard function h X (t) describing the potential for the focal event X to happen exactly at time t, that is, the evolution of the intensity of the process over time (Choquet, Garnier, Awuve, & Besnard, 2017):

| Sampling duration
In a first analysis, we considered that all three processes-survival, reproduction and detection-occur at a constant rate throughout the year. Hence, we considered the different hazard rates h S , h R and h P (survival, reproduction and detection hazard rates, respectively) to be constant over time: The corresponding survival function is then an exponential model describing the evolution of the probability for an individual to die after time t (i.e. survive to time t): However, for the reproduction and detection processes, we are interested in the probability to reproduce or be detected before time t, not the probability to reproduce or be detected after time t. Hence, we used the complementary functions ( Figure 2b): It is worth noting that, when λ S = 0 and λ R = 0, all individuals survive indefinitely (S t = 1) and no individual reproduces (R t = 0). This scenario corresponds to a population fulfilling the closure assumption ( Figure 2a).

| Sampling timing
In a second analysis, we considered scenarios where both survival and recruitment hazard rates varied throughout the year following a normal distribution. This setting corresponds to the situation where most mortality and reproduction occur during a limited period of the year, as it is the case for many animal populations (Healy, 2003;Rowan, 1938): where μ, the mean of the normal distribution, corresponds to the mid-point of the survival or recruitment time-to-event functions,

| SCR modelling
For the purpose of our study, we used a Bayesian approach and constructed an SCR model with data augmentation to allow for the estimation of population size (Royle & Dorazio, 2012  (c) the detection model, which describes the probability for an individual i to be detected at a given detector j. In this characteristic feature of SCR models, the probability to detect individual i at detector j, p ij is a function of the distance d ij between its activity centre s i and the location of detector j. Here, we used the commonly used half-normal function (Borchers & Efford, 2008): where p 0 is the baseline detection probability and σ is the scale parameter (Royle et al., 2013).
Finally, the detection data y ij is modelled as the realization of a Bernoulli process conditional on both the individual state z i and the individual and detector-specific detection probability p ij :

| General population characteristics
We

| Sampling duration
, recruitment R(t), and detection D(t) functions (scale on the left, solid lines); number of individuals available for detection and number of individuals detected (scale on the right, coloured polygon) for (a) a closed population, (b) a population with constant mortality and recruitment over the course of the year and (c) seasonal mortality (peak in mortality occurs during month 7) and recruitment (peak in recruitment occurs during month 3). The vertical dashed lines represent the start and end of the sampling periods rates λ P = 0.1, 0.5 and 1.2. We repeated the simulation process 100 times for each parameter configuration, leading to 13,200 simulated datasets.

| Sampling timing
Next, we tested the effect of the timing of the sampling period on bias and precision of SCR estimates for populations with seasonal demographic rates. Here, we only generated SCR datasets for the slow, intermediate and fast species, as the closed population has no seasonal variation in demographic rates by definition. The timing of the sampling period is therefore irrelevant in a closed population situation. Sampling duration was set to t max = 0.5 year and we varied the starting date of the sampling period relative to the peaks of the reproductive and mortality periods (μ in Equation 6). This simulation study comprised 11 different starting dates (between −0.5 and +0.5 years before and after the peak in mortality) for the three life-history scenarios with 100 repetitions each, leading to 9900 simulated datasets. The different demographic rates used in the simulations are presented in Table 1.

| Simulation procedure
For simplicity, we refer to mortality and reproduction only in the following section, but the same procedure holds true if we were to consider emigration and immigration. The procedure for generating simulated datasets was as follows (  (Table 1).

3.
The time at death for each offspring produced (TaD n.off ) was then sampled from the same survival function S t as for the adults.

4.
Based on the time at death, the time an individual was available for detection (T i ) was then deduced: -For individuals present a t 0 , T i was set to TaD i or to t max if they survived the entire sampling period.
-For individuals born during the sampling period, T n.off corresponded to the difference between TaD n.off and TaB n.off if they died before the end of the sampling period or to the difference between t max and TaB n.off otherwise.
Individual baseline detection probability p 0i given T i (equivalent to P it ) was then calculated using Equation 5. 5. Individual activity centres s i were randomly generated following Equation 7. 6. p ij was then calculated using Equation 10.

7.
The individual detection history y ij was generated following Equation 11. Finally, we augmented the simulated dataset with all-zeros detection histories to reach a total of M = three times the number of individuals ever available for detection.
In addition to this SCR-specific simulation study, we also implemented a similar simulation approach to check for the influence of the sampling period characteristics on population size estimates returned by classical (non-spatial) CR models (Supplementary Material 3).

| Model fitting
We fit SCR models in JAGS (Plummer, 2003) through R (R Core Team, 2017) via package jagsUI (Kellner, 2015) to all simulated TA B L E 1 Demographic and detection rates used in the different scenarios of the simulation study  For all analyses, we considered models to have reached convergence when the potential scale reduction value Rhat < 1.1 for all parameters (Gelman & Rubin, 1992). In addition, we checked that the number of iterations was sufficient and that the different chains showed good mixing properties by visually inspecting the trace plots of the different parameters for a subset of simulations.

| Simulations evaluation
To evaluate the performance of our SCR model to recover the simulated population size under the different scenarios tested, we looked at two frequentist properties of the Bayesian estimator. As a measure of the accuracy of the SCR estimator of population size, we used the mean , where N J is the mode of the posterior population size distribution from the j th simulated dataset and N is the true value of population size. Note that we refer to the number of individuals at the start of the sampling period in each simulation (N = 40) as the true population size. As a measure of precision, we used the mean over all simulations of the posterior population size standard deviation.

| RE SULTS
All 13,200 runs for the sampling duration simulation study reached convergence. Out of the 9900 runs of the sampling timing simulation F I G U R E 3 Diagram of the simulation procedure for an individual present at the beginning of the sampling period and associated offspring. The different simulation steps are described in method section 2.3.4 study, only one did not reach convergence (Rhat values >1.6) and was therefore excluded from subsequent analyses.

| Closed population
When the closure assumption was met, lengthening the sampling period increased both precision and accuracy of the population size estimate returned by the SCR model (Figure 4e, i). While relative bias was around 100% for the shortest sampling periods (0.05 years), it quickly fell below 20% for sampling periods over 0.4 years when about 80% of the individuals present in the population were detected (Figure 4e). The associated standard deviation also decreased with sampling duration reaching an asymptote at approximately 3 for sampling periods over 0.4 years (Figure 4i).

| Slow life history
Similar to the results obtained for the closed population, we observed a decrease in both relative bias and standard deviation as the duration of the sampling period increased (Figure 4f,j). In addition, the timing of the sampling period did not induce noticeable additional bias or imprecision in population size estimates (Figure 5d,g). Instead, population size estimates displayed a high precision (standard deviation less than 3 for all sampling period starting dates, Figure 5g) and accuracy (relative bias below 10% for all starting dates, Figure 5d). and relatively low as long as the sampling period did not overlap the breeding season. The relative bias then increased as the sampling period progressively overlapped the reproductive period to reach approximately 40% after the peak of the reproductive period ( Figure 5e). The associated standard deviation also increased as the sampling period overlapped more and more with the reproductive period ( Figure 5h).

| Fast life history
For the fast life-history strategy, the number of detected individuals was already higher than the original population size after a sampling period >0.4 years. The total number of detections also increased and was about 2.5 times higher than for the slow life-history scenario.
Mean standard deviation associated with population size estimates F I G U R E 5 Overall number of detections (in grey, a, b and c), number of individuals detected (in blue, a, b and c), relative bias (in red, d, e and f) and standard deviation of population size estimates (in red, g, h and i) as a function of timing of the sampling period (x-axis) and life-history strategies (left to right panel). The timing of the sampling period is expressed relative to the peak in mortality (red vertical dashed line). The green vertical dashed line represents the peak in reproduction. Red and green Gaussian polygons represent mortality and reproduction hazard rates respectively (g, h and i). Solid lines represent mean values over 100 repeated simulations and shaded areas represent the associated 95% confidence interval. NB: In the top and bottom rows, the scales differ between the number of detections or standard deviation (left side) and the number of individuals detected or hazard rates (right side) respectively decreased with sampling period in a fashion similar to the other simulation scenarios, albeit with greater variability as indicated by the larger standard error. Contrary to the intermediate scenario, the relative bias never decreased and instead steadily increased to reach very high levels (over 150%; Figure 4h) as soon as the sampling period exceeded 0.1 years.

Similar to the intermediate scenario, the bias in population size
estimates was virtually null as long as the sampling period did not overlap the breeding season, before increasing to reach its highest level when the sampling period starting date coincided with the peak of the reproductive season (at 0.4 years; Figure 5f) before finally decreasing again. The associated standard deviation followed a similar pattern of increase and subsequent decrease (Figure 5i).

| D ISCUSS I ON
We found that lengthening the sampling period during SCR studies is an effective way to increase the amount of information available for analysis, thereby boosting the precision of population size estimates.
On the other hand, longer sampling periods can lead to violations of the population closure assumption and biased estimates. The shape of this bias-precision trade-off is dependent on the life-history speed and scheduling of the study species.
The gains in sample size from longer sampling periods improve the precision of abundance estimates generated by SCR models, as has also been shown for traditional CR estimators (O'Brien et al., 2005;Otis et al., 1978;Pollock, Nichols, Brownie, & Hines, 1990).
Even a modest gain in terms of the number of samples collected and individuals detected can lead to a pronounced gain in the estimator's precision. We found, for example, that doubling the sampling period from 0.1 to 0.2 years brought along between 20% and 55% increase in the number of individuals detected and between 69% and 100% increase in the overall number of detections in our closed population and fast life-history scenarios respectively. The subsequent boost in the precision of the population size estimator is not trivial; it increased by 78%, 76%, 72% and 10% for the closed, slow, intermediate and fast-living scenarios respectively.
In addition to gains in precision, we also found that increased sample size can reduce bias associated with sparse SCR data. This is consistent with previous findings for classical capture-recapture methods (Chao, 1989, Supplementary Material 3). Specifically, Chao showed that the amount of bias in CR population size estimators obtained using Bayesian methods was sensitive to the choice of priors.
Akin to this, the large overestimation we observed for shorter sampling periods is most likely the result of our choice of the augmented population size M. When data are sparse, it contains very little information and the resulting posterior distribution of the population size estimates is mostly influenced by its prior distribution (here, a flat prior between 0 and M = three times the total number of individuals ever available for detection). More specifically, when data are sparse, the distribution of the population size bias is skewed towards high values (Figure 4), indicating that the population size estimates returned by SCR models are constrained by the upper possible bound (i.e. the augmented population size M). Interestingly, this pattern seems to be even more pronounced for non-spatial capture-recapture models (Supplementary Material 3). Our findings regarding the benefits of longer study periods have important implications, especially for rare and elusive species often targeted by SCR studies (Gray & Prum, 2012), as their study tends to be hampered by data sparsity due to rarity and low detection probabilities. Furthermore, these are the species-data deficient and often threatened-where improvements in our ability to make inferences are particularly consequential, as they can inform sustainable management and conservation (Blanc et al., 2013;Gervasi, Ciucci, Boulanger, Randi, & Boitani, 2012). pling. This may explain the existing notion that CR methods were relatively robust to closure violations (Hargrove & Borland, 1994;Kendall, 1999;O'Brien et al., 2005;Rota et al., 2009, but see the discussion in Otis et al., 1978). In our study, where both recruitment and mortality were considered, we detected biases in population size of up to 300% when using year-long sampling periods to study species with fast-paced life histories (Figure 4h; Supporting Information 3).
In natural populations, both recruitment and mortality often peak during limited periods of the year (such as breeding and hunting seasons; Marra et al., 2015). The severity of closure violation is therefore influenced not only by the duration, but also by the timing of the sampling period relative to the focal species' annual cycle. Our simulations revealed that the timing of the sampling period relative to the mortality period had little impact on the SCR estimators' bias, probably because, for the length of sampling period and mortality rates considered here, most individuals were detected before they died (see also O'Brien et al., 2005). For the same reason, the timing of the sampling period relative to the mortality period also seems to have limited impact on the SCR estimators' precision. Conversely, sampling periods that included the peak in recruitment led to marked increases in both bias and imprecision of the population size estimator ( Figure 5). The In real-life situations, it may be possible to account for this type of issue even when the sampling period includes the recruitment season.
Certain monitoring methods-for example camera trapping, direct observations or physical captures-allow direct identification of new recruits, such as juvenile individuals. These can then either be accounted for in the analysis, using age-specific detection functions or excluded from it. Other methods (e.g. NGS) may not allow for the identification of new juvenile recruits when they enter the population during the sampling period (but see Stenglein, Waits, Ausband, Zager, & Mack, 2011;Woodruff, Johnson, & Waits, 2016). Also, other types of new recruits (e.g. immigrating adults) may not be distinguishable from the rest of the population. Failing such distinction, investigators should strive to time the sampling period to fall outside peak seasons of recruitment (Brøseth, Flagstad, Wärdig, Johansson, & Ellegren, 2010).
Another potential limitation of our study is related to the space use of juvenile individuals. In our simulations, we did not account for the fact that juveniles often stay associated with their parents until they are weaned. This association might be negligible for short-lived species in which juveniles become independent quickly, but could be problematic for long-lived species where parents-offspring association can last longer (e.g. around 1-2 years in many large mammals; Bischof et al., 2018). This would then result in violations of the assumption of independence between individuals' activity centres.
However, this particular situation is probably not problematic, as far as population size inferences are concerned, since SCR methods have been shown to be comparatively robust to the violation of independent individual placement (López-Bao et al., 2018).
The time-to-event approach we employed here enabled capturing short-term population dynamics and their repercussions for inferences drawn from realistic, non-instantaneous, sampling periods. Investigators can emulate our simulation framework in order to guide decisions regarding the length and timing of the sampling period for their specific situation. Moreover, this approach can be easily adapted to incorporate greater realism, for example by accounting for variable sampling effort over time, a common feature of many monitoring programs. This can be accomplished by allowing time varying detection hazard rates (e.g.
in the same way as the survival and reproduction hazard rates, see Supporting Information 1). Similarly, the survival hazard rate function could also be modified to account for the age of the individuals at the time they enter the population. This would allow mimicking the typical situation (especially for long-lived species) where juveniles have lower survival rates than individuals old enough to breed (Promislow & Harvey, 1990). Finally, the time-to-event approach presented here proved useful to generate realistic data and test the robustness of SCR and CR methods to violations of the population closure assumption, but one could also consider continuous time capture-recapture models to study such continuous processes. Despite a great potential for application in capture-recapture studies, this framework has not been widely used so far (but see Choquet, Viallefont, Rouan, Gaanoun, & Gaillard, 2011or more recently Ergon, Borgan, Nater, & Vindenes, 2018, and we encourage further studies to consider this analytical framework.

| CON CLUS ION
Facing the need for large sample sizes and the desire to minimize population closure violations, how should investigators design their sampling period in SCR studies? Using a time-to-event approach, we were able to identify the bias-precision trade-off inherent in the choice of the sampling period, which was mediated by the lifehistory characteristics of the species under study. We therefore encourage researchers/wildlife managers to pay particular attention to the biology of their study species when designing sampling protocols. Our results show that lengthening the data collection period is an effective way to increase the number of detections, which can then lead to substantial improvements in the precision of estimates and in some cases make meaningful analyses possible in the first place. Violations of the population closure assumption arising from longer sampling durations have negligible consequences for longlived species at the slow end of the slow-fast life-history continuum. This is an important and reassuring finding, as these are often the species with the greatest need for conservation and thus reliable information about population status. Although closure violations have more pronounced consequences for SCR inference for species with fast-paced life histories, investigators can often mitigate these by using sampling durations that balance precision and bias, and by avoiding periods of peak recruitment during sampling. Based on the patterns we observed in this study, we argue that a general rule of thumb should be to extend the sampling period as much as practically/economically feasible, while avoiding sampling during recruitment bouts.