-
Notifications
You must be signed in to change notification settings - Fork 54
Index standardization
Jim Thorson edited this page May 8, 2023
·
4 revisions
I here demonstrate my efforts to develop high-level functions to simplify running VAST
for several common model purposes. The default structure shown here is for "index standardization."
# Load package
library(VAST)
# load data set
# see `?load_example` for list of stocks with example data
# that are installed automatically with `FishStatsUtils`.
example = load_example( data_set="EBS_pollock" )
# Make settings (turning off bias.correct to save time for example)
settings = make_settings( n_x = 100,
Region = example$Region,
purpose = "index2",
bias.correct = FALSE )
# Run model
fit = fit_model( settings = settings,
Lat_i = example$sampling_data[,'Lat'],
Lon_i = example$sampling_data[,'Lon'],
t_i = example$sampling_data[,'Year'],
b_i = example$sampling_data[,'Catch_KG'],
a_i = example$sampling_data[,'AreaSwept_km2'] )
# Plot results
plot( fit )
This should provide an abundance index for whichever species is chosen in load_example
, which loads Alaska pollock in the eastern Bering Sea by default. To use VAST
with a new data set, input new data in the same format as example data and see ?make_data
for more details.
Example applications:
- Index standardization
- Empirical Orthogonal Functions
- Ordination using joint species distribution model
- End-of-century projections
- Expand length and age-composition samples
- Combine condition and biomass data
- Expand stomach content samples
- Combine presence/absence, counts, and biomass data
- Seasonal and annual variation
- Combine acoustic and bottom trawl data
- Surplus production models
- Multispecies model of biological interactions
- Stream network models
Usage demos:
- Adding covariates
- Visualize covariate response
- Percent deviance explained
- Create a new extrapolation grid
- Custom maps using ggplot
- Modify axes for distribution metrics
- K-fold crossvalidation
- Simulating new data
- Modify defaults for advanced users
Project structure and utilities: