## How should I subdivide my transects into smaller units for spatial modeling? ## Most studies have split transects into segments of approximately equal length, as proposed by the original density surface modeling papers (e.g. [Hedley and Buckland 2004][1]): ![Hedley and Buckland (2004) Fig. 4.4][2] Practitioners have also split them into cells, e.g. by intersecting them with a fishnet of square polygons. For example, [Chavez-Rosales et al. (2019)][3] split NEFSC AMAPPS surveys into 10 km x 10 km x 8-day cells. ## What length should my segments be? ## Ideally, for density surface models, the segments should be small enough such that neither density of objects nor covariate values vary appreciably within a segment ([Miller et al. 2013][4]). Non-varying covariates should include both those used in the detection model and those used in the spatial model. It is also commonly suggested that segment length be set to twice the right truncation distance, resulting in a surveyed area that is approximately square. However, on aerial surveys, truncation distances can be quite small (< 1000m), yielding a large number of segments. If covariates are at a much coarser scale, this can lead to many segments with very similar covariate values, which may not be desirable. The most rigorous approach is to conduct a sensitivity analysis to determine whether segment length matters for your situation, although reports of such experiments in the literature are rare. In general, segments of 1 to 25 km have frequently been used when modeling marine mammals from aerial or shipboard line transect surveys. ## Must all segments be the same length? What if the trackline length is not evenly divisible by the segment length? How should I handle the remainder? ## It is not required that all segments be the same length. Although it is possible to adopt a segmenting method that forces them to be the same length--e.g. split them into a target segment size and discard any remainder--it is unlikely that they will be the same *width* if the detection function uses any covariates. Thus it is unlikely that all segments will represent the same effective area, even if they are the same length. In the traditional method to the spatial modeling stage, which fits a generalized additive model (GAM) to the segments, the effective area is used as a model offset. This allows the model to account for segments having different effective areas. We believe there might be some benefit to minimizing the range and variability in effective areas of segments, when practicable. In our experience, the most important thing to watch out for are segments with small areas that have non-zero abundance. The non-zero segments with very low area represent extreme densities that can cause problems in model fitting. Therefore, when splitting a long transect into a target length, it might be better to divide up any "remainder" evenly among the segments, or add it to the last segment, or just throw it out, than to leave a short segment. Similarly, it is not desirable to have extremely long segments. Such segments may span gradients in density, covariates, or both, yet they must aggregate abundance and covariates into single values. In this way, they smooth out gradients that might otherwise be detected. ## What tools can help me split tracklines into segments? ## ### Marine Geospatial Ecology Tools ### With the free [Marine Geospatial Ecology Tools (MGET)][5] plugin to ArcGIS, you can do this with a two-step procedure: 1. Split the tracklines into segments 2. Match the sightings to segments by time as shown in this geoprocessing diagram below. **If you have additional tools to recommend please contact us.** ![Geoprocessing worflow for splitting tracklines into segments with MGET][6] ### dshm R package ### The [density surface Hurdle modelling (dshm)][7] R package provides a function dshm_split_transects that can split transects into segments. A [vignette][8] provides a detailed example of using this function. ### Vignette on data processing for DSMs in R ### An example using the sf R package is available [on the distance sampling website examples page](9) showing how to segment transects and the tools required to do so in R. [1]: https://doi.org/10.1198/1085711043578 [2]: https://files.osf.io/v1/resources/wgc4f/providers/osfstorage/5c65ef6214312700169e8fec?mode=render [3]: https://doi.org/10.1038/s41598-019-42288-6 [4]: https://doi.org/10.1111/2041-210X.12105 [5]: https://mgel.env.duke.edu/mget/ [6]: https://files.osf.io/v1/resources/wgc4f/providers/osfstorage/5cf6e802fe9cf5001abd4ae9?mode=render [7]: https://github.com/FilippoFranchini/dshm [8]: https://github.com/FilippoFranchini/dshm/raw/master/vignettes/split_transects.pdf [9]: https://examples.distancesampling.org/dsm-data-formatting/dsm-data-formatting.html