Skip to content

Snow crab fishery assessment for Maritimes region of Canada

License

Notifications You must be signed in to change notification settings

jae0/bio.snowcrab

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Stock assessment of Canada's Maritimes Region snow crab (Chionoectes oplio) leveraging aegis*, bio*, and packages.

This project, bio.snowcrab, is used by the Maritimes snow crab group to:

  • Assimilate data from various sources:
    • Minilog, Seabird, Marport, GPS data streams
    • Snow crab survey data, entered into the At-Sea-Observer data base system
    • Logbook data of landings and effort ( 100% monitored )
    • At-sea-observed fisheries data ( 5% of catch monitored )
  • QA/QC
  • Model spatiotemporal variations of number (Poisson process) and mean body weight (Gaussian process) using Bayesian Conditional Autoregressive Models. Heavy lifting is done by INLA[https://www.r-inla.org/].
  • Model aggregate timeseries by region as Bayesian biomass dynamics autoregressive process (Logistic form) using STAN and obtain biological parameters that guide Harvest control rules.
  • Generate routine figures, tables, reports and presentations.

Much of this project is generic and can be easily ported/adapted for other species. Usage is shown in the scripts found in inst/markdown/0*.md. They represent the backbone of the assessment.

Quarto documents (a structured markdown format) can be found in inst/markdown/. They are meant to be copied to a work directory (current defaultis: bio.data/bio.snowcrab/assessments/{year} ) where they can be run to generate reports on demand. The Makefile contains the instructions on report generation.

There is heavy reliance upon aegis.bathymetry, aegis.polygons, aegis.surveys and aegis.temperature. Though not necessary, they help inform the broader ecosystem-based approach that has been used with snow crab assessments since 2004 (when we received the mandate in Maritimes Region). Examples of their usage are found in the individual aegis.* projects inst/scripts/0*.md files.


Installation:

  1. To install:
  install.packages( "remotes", ask=FALSE, dependencies=TRUE ) # to inter-operate with github
  remotes::install_github( "jae0/aegis" ) # to bootstrap by installing directly from github
  remotes::install_github( "jae0/bio.snowcrab") # install bio.snowcrab and other required packages
  1. Then, you need to have an Rprofile set up properly. Use the following, being careful to define the required R-global variables (see also: https://github.com/jae0/aegis/src/master/R/project.Rprofile.example.r):

homedir = path.expand("~")
code_root = file.path( homedir, "bio" )   ### replace with correct path to the parent directory of your git-projects
data_root = file.path( homedir, "bio.data" )   ### replace with correct path to your data

require( aegis )

# store your passwords and login here and make sure they are secure
# try ( source( file.path( homedir, ".passwords" ) ) )


A more expanded version, similar to what we use, can be found below:

https://github.com/jae0/aegis/blob/master/inst/scripts/example_Rprofile.R

About

Snow crab fishery assessment for Maritimes region of Canada

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •