Loading Functions

Functions that load in and process atlantis output

load_box()

Load the box specification file for an Atlantis scenario

load_bps()

Extracts the names of the epibenthic biomasspools from the initial conditions file.

load_dietcheck()

Read in the atlantis dietcheck.txt file and perform some basic data transformations.

load_dietmatrix() write_diet()

Extract the dietmatrix from the biological parameterfile

load_fgs()

Load the functional group file

load_init()

This function is used to read in data from the initial conditions file.

load_init_age() load_init_nonage() load_init_stanza() load_init_physics() load_init_weight()

This function loads weight at age data (in mgN) from the initial conditions file.

load_mort()

Load mortality information from outputMort.txt

load_spec_mort()

Load mortality information from specificMort.txt

load_spec_pred_mort()

Load mortality information from outputSpecificPredMort.txt

load_nc()

Load Atlantis outputfiles (netcdf)

load_nc_physics()

Load Atlantis outputfiles (netcdf)

load_rec()

Load information for SSB and Recruits from an Atlantis model run.

load_txt()

Function to load various txt files from Atlantis simulations

preprocess_txt()

Preprocess dataframes loaded in with load_txt()

preprocess

preprocess

calculate_biomass_spatial()

Calculate spatially explicit biomass (in [t]) for each group and ageclass per timestep.

calculate_consumed_biomass()

Calculate the consumed biomass in [t] of prey j by predator i.

calculate_spatial_overlap()

Calculate 3d overlap of predator groups with their prey over time using Schoener Index.

Get/manipulate parameter values

Functions that pull parameter values from parameter files

extract_prm() extract_prm_cohort()

Extract values for Atlantis parameters from the biological parameter file.

scan_prm()

Scan character vector for specific flag!

prm_to_df() prm_to_df_ages()

Extract parameters from the biological parameter file and transform them to a dataframe.

change_prm()

Change biological parameterfile to simplify automated ATLANTIS calibrations.

change_avail()

Change the availability matrix to simplify automated ATLANTIS calibrations.

Get functions

Functions that pull other atlantis information

get_boundary()

Get boundary boxes from Atlantis box information.

get_colpal()

Create discrete color palette used in plots.

get_conv_mgnbiot()

Extract conversion factor used to transform data from nitrogen in mg to biomass in tonnes.

Get functional group info

Functions that pull information from the functionaGroups.csv file

get_groups() get_age_groups() get_acronyms() get_age_acronyms() get_nonage_acronyms() get_fish_acronyms() get_cohorts_acronyms() get_fished_acronyms() get_turnedon_acronyms()

Collection of similar functions which get specific columns from the Atlantis functionalGroups.csv

Fishbase/online data

Functions that pull information from fishbase and other online sources

fishbase_data

fishbase_data

get_diet_fishbase()

Extract reference for diet information from http:://www.fishbase.se

get_ids_fishbase()

Extract fishbase IDs using the package "rfishbase" to generate species specific fishbase URLs

get_growth_fishbase()

Extract growth parameters from http:://www.fishbase.se.

get_maturity_fishbase()

Extract maturity parameters from http:://www.fishbase.se.

get_ref_biotic()

Extract bibliographic info from www.marlin.ac.uk/biotic.

get_ref_fishbase()

Extract the bibliographic info from www.fishbase.org.

scan_reference_fishbase()

Scan list of references for character string for fish species

Plotting

Plotting functions to output

theme_atlantis()

Customized theme used in all plots.

flip_layers()

Flip layers for visualization.

custom_grid()

Utility functions used for various plotting routines within atlantistools.

plot_add_box()

Low level plotting function to add sudo confidence range to calibration plots.

plot_add_polygon_overview()

Add spatial representation of polygon layout to a ggplot2 object.

plot_add_range()

Low level plotting function to add range of observed values to time series plots.

plot_bar()

Function to plot relative contribution of biomass and numbers per cohort.

plot_boxes()

Plot layout of boxes!

plot_consumed_biomass()

Circle diagram to visualize the consumed biomass for the whole system.

plot_diet()

Plot contribution of diet contents for each functional group.

plot_diet_bec_dev()

Plot contribution of diet contents for each functional group.

plot_line()

Function to plot time series of atlantis ncdf output.

plot_rec()

Plot recruitment.

plot_spatial_box()

Visualize the spatial distribution per species and stanza combination.

plot_spatial_overlap()

Plot spatial overlap.

plot_spatial_ts()

Visualize the spatial distribution per species and stanza combination.

plot_species()

Create species specific overview plot.

sc_init() plot_sc_init()

Sanity check initial conditions file

Miscellaneous

Other functions

str_split_twice()

Extract numeric values from string.

convert_time()

Convert timestep to actual time!

convert_relative_initial()

Calculate relative timeseries using the initial value as benchmark.

convert_factor()

Function to convert any column with information about functional groups to a factor whose levels use the LongName of the functional groups file.

convert_bgm()

Transform data from bgm-file to map dataframe.

combine_runs()

This function is used to combine model output from different simulations!

combine_groups()

Combine values from different groups if specific groups only have a low contribution to the overall value.

combine_ages()

Combine ageclasses to juvenile and adult stanza according to age at maturity.

check_growth()

This function is used to check the individual growth per group over time.

check_df_names()

Function to check the names of a dataframe.

change_prm_cohort()

Change biological parameterfile for parameters which expect multiple values.

agg_data() agg_perc() group_data()

Aggregate data using dplyr functionality.

%>%

Pipeoperator

Ref functions

???

ref_agemat

agemat.

ref_bio_cons

Consumed biomass.

ref_bio_sp

Spatial biomass.

ref_dietmatrix

Dietmatrix.

ref_dm

Dietcheck.

ref_eat

Eat.

ref_grazing

Grazing.

ref_growth

Growth.

ref_lit

Reference dataframe

ref_n

Nitrogen.

ref_nums

Numbers at age data.

ref_physics

Physical variables.

ref_resn

Reserve nitrogen.

ref_structn

Structural nitrogen.

ref_to_bibkey()

Convert reference to bib-tex-key.

ref_vol

Volume.

ref_vol_dz

Volume and dz.