This repository contains code and data for:
Davidson, L.N.K., P.A. English, J.R. King, P. Grant, I.G. Taylor, L. Barnett, V. Gertseva, C.A. Tribuzio, and S.C. Anderson. 2025. Mystery of the disappearing dogfish: transboundary analyses reveal steep population declines across the Northeast Pacific with little evidence for regional redistribution. Fish and Fisheries. https://doi.org/10.1111/faf.70028
data-raw/: Raw data files from trawl and longline surveysdata-prep/: Scripts for data wrangling and preparationanalysis/: Statistical modeling and analysis scriptsoutput/: Model outputs and processed resultsfigs/: Figures generated for the publication
The analysis requires R and the following packages (other packages on CRAN):
Install required packages with:
install.packages("tidyverse")
install.packages("concaveman")
install.packages("cowplot")
install.packages("data.table")
install.packages("inlabru")
install.packages("marmap")
install.packages("pak")
install.packages("patchwork")
install.packages("RColorBrewer")
install.packages("RhpcBLASctl")
install.packages("sf")
install.packages("spatioEco")
install.packages("wesanderson")
pak::pak("pbs-assess/sdmTMB@dec92c1", dependencies = TRUE)
pak::pak("pbs-assess/gfiphc")
pak::pak("pfmc-assessments/nwfscSurvey")
pak::pak("seananderson/ggsidekick")
pak::pak("ropensci/rnaturalearthhires")
pak::pak("eliocamp/tagger")
pak::pak("[email protected]")
pak::pak("[email protected]")The analysis can be reproduced by running scripts in sequence:
- Data preparation: Run
data-prep/00-run-all.Rto prepare all survey data - Statistical analysis: Run
analysis/000-run-all.Rto fit models and generate figures
Alternatively, run individual scripts in numerical order within each directory.
Running the full analysis will take several hours.
Setting up R with an optimized BLAS library will substantially speed up model fitting.
For questions about this code, please open an issue or contact the paper's corresponding author.