DOI: 10.5061/dryad.cz8w9gjfn
title: Data from: Unobserved individual and population level impacts of fishing gear entanglements on North Atlantic right whales

description: Fishing gear entanglements can compromise health and lower survival and
 reproductive output of wildlife, which can slow population growth or cause
 population declines. However, entanglements may go unobserved, making it
 difficult to quantify their effects on individuals’ vital rates and a
 population’s trajectory. Fishing gear entanglements are a leading cause of
 death for North Atlantic right whales, Eubalaena glacialis, an endangered
 species whose population has declined substantially over the last decade.
 Key sources of observation error have not been addressed when quantifying
 the effects of entanglement on this species. We formulated a hidden Markov
 model that integrated 28 years of photo identification records, visual
 health assessments, entanglement assessments, and hormone assays to
 estimate body condition dynamics, and entanglement, survival, and
 reproductive rates of female North Atlantic right whales. The model also
 accounted for observation errors, including entanglements and reproductive
 events that were unobserved. Whales entangled in fishing gear were
 drastically more likely to experience declines in body condition and had
 lower survival rates than whales that were not entangled. Additionally,
 only whales in good body condition became pregnant. Between 1994 and 2021
 entanglements reduced the expected number of calves born by 12.9% (95%
 credible interval: 8.2% – 19.6%) and the expected number of females alive
 at the end of 2021 by 18.5% (95% credible interval: 8.6% – 29.4%). Fishing
 gear entanglements have reduced the North Atlantic right whale
 population’s capacity to recover and have increased the importance of the
 health and survival of the remaining living whales. Therefore, reducing
 the risk of fishing gear entanglements is likely necessary for the
 population to recover. 
description: # Unobserved individual and population level impacts of fishing gear
 entanglements on North Atlantic right whales
 [https://doi.org/10.5061/dryad.cz8w9gjfn](https://doi.org/10.5061/dryad.cz8w9gjfn) ## Description of the data and file structure North Atlantic right whale sightings histories, visual health assessments, and entanglement assessments ### Files and variables #### File: Model\_data\_and\_constants.RData **Description:** Contains two lists (constants and hormone_data), which are used to fit a hidden Markov model to estimate North Atlantic right whale survival, reproductive, health, and entanglement state dynamics.  constants contains the following variables:   nind - number of individual right whales in the dataset   n.occasions - number of sampling occasions in the time series   n.prim.per.year - number of sampling occasions within each year   f.primary - vector; occasion of first sighting for each individual   f.year - vector; year of first sighting for each individual   n.year - number of years in the time series hormone_data contains the following variables:   y - matrix; row *i* is the sighting history for individual *i* where the *j*-th element of row *i* represents the following     0 - not sighted     1 - sighted with a calf in the Southeastern U.S.     2 - sighted without a calf in the Southeastern U.S.     3 - sighted with a calf elsewhere     4 - sighted without a calf elsewhere     13 - reproductive hormones assayed and fecal progesterone &gt; 10,000 ng/g (i.e., pregnant)     14 - reproductive hormones assayed and fecal progesterone &lt; 10,000 ng/g (i.e., not pregnant)     23 - sighted dead and pregnant     24 - sighted dead and not pregnant     25 - sighted dead and pregnancy status not assessed   timeOFyear - vector; temporal covariate representing time of year for each    f.age - vector; age at first sighting for each individual (N/A if unknown and 11 if 11 years or older)   SE.effort - vector; number of aerial surveys flown in the Southeastern U.S. each sampling occasion   NE.effort - vector; number of aerial surveys flown outside the Southeastern U.S. each sampling occasion   NE.boat - vector; number of boat based surveys conducted outside the Southeastern U.S. each sampling occasion   vh.bf - matrix; row *i* is the visual health assessment history for individual *i *where the *j*-th element of row *i* represents the following     0 - body condition not assessed     1 - good body condition     2 - fair body condition     3 - poor body condition   ent.cov - matrix; row *i* is the entanglement assessment history for individual *i *where the *j*-th element of row *i* represents the following     0 - no new entanglement related information observed     1 - new entanglement scar observed     4 - new entanglement with attached fishing gear observed     7 - last observation before a new entanglement observation     8 - first observation without attached fishing gear after being sighted entangled with attached fishing gear     100 - dead and not entangled     104 - dead and entangled     109 - dead and entanglement status unknown ## Code/software Software used to conduct the analysis included program R v4.2.1 and the R package nimble v0.13.1. To replicate the analysis download the **Model data and constants.RData** file and run the **Model code.R** script. The script requires that you set your working directory to the folder where the data file has been saved. The **Nimble model restart functions.R** script must also be saved in the working directory. The script will save output files to the working directory and includes a section to restart the model if needed. After the model has converged the **Posterior predictive checks.R** script can be used to derive quantities associated with the counterfactual analysis reported in the paper. This script sources functions from the **Forward algorithm.R**, **Backward algorithm.R**, and **HMM functions.R** scripts.