Calculates the number of tows per strata and strata weight. Run before sub setting the data by species of interest to ensure all stations are accounted.
Usage
strat_prep(
surveyData,
areaPolygon = "NEFSC strata",
areaDescription = "STRATA",
filterByArea = "all",
filterBySeason = "all"
)Arguments
- surveyData
Data table. NEFSC survey data generated by
get_survdat_data.R- areaPolygon
sf object or character string. Default = "NEFSC strata". The default option uses the survey strata shapefile bundled with the package. To use any other shapefile for stratification, the shapefile must be read in as an sf object and the
areaDescriptionargument must be specified.- areaDescription
Character String. Column name from
areaPolygonthat contains the strata designations.- filterByArea
Numeric vector. Set of areas to subset from the
areaDescriptionof theareaPolygon.- filterBySeason
Character string. Which seasons of the
surveyDatashould be included. Choices include "SPRING", "FALL", or "all".
Value
Returns a prepSurvey data object with added columns for the number of tows (ntows) and stratum weights (W.h).
See also
Other internal:
post_strat(),
strat_mean(),
swept_area()
