5 Step 5 - Perform Assessment Methods

What do my assessment methods say about the fishery?

Step 5

Figure 5.1: Step 5

During this step, you will use your data to calculate performance indicators using the chosen assessment methods. Refer to the assessment method descriptions under Step 3 for detailed descriptions of the assessment methods. To do the calculations, you may use the AFAM Toolkit dashboard.

The dashboard includes data templates you may fill out using your own data to ensure all data are properly formatted for analysis. Alternatively, the dashboard also specifies the necessary columns for all types of data input, so you could also simply make sure your data has all necessary column names. Importantly, all column names must match exactly what is specified in the dashboard.

The dashboard currently comes pre-loaded with the necessary life history information for many species commonly found in the Philippines, Indonesia, Mozambique and Brazil. If your species is currently included, you should ensure the life history parameters look reasonable for your particular site. If they are not included, you will need to find these parameters by looking through the literature and using resources such as FishBase

If you do not have R installed on your computer, you should first install R and R Studio on your computer using these instructions.

Next you will install the AFAM package onto your computer so that you can use it in R and R Studio.

5.1 Installling the dashboard from the internet

This is the best option and should be chosen if you have internet connectivity. This will install the AFAM package onto your computer from an online file sharing service (“Github”). This will ensure that your version of the app is the most up-to-date as possible. Note that this step requires internet connection.

If you choose this option, simply copy and paste the following code into your R Studio console and run the code.

## Specify packages that are required for AFAM app. Install them if they're not installed already
list.of.packages <- c("tidyverse", "gridExtra", "pander", "shiny", "DT","devtools","readxl","stringr","LBSPR","TropFishR","lubridate","zoo","curl")
new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])]
if(length(new.packages) > 0 ) install.packages(new.packages, dependencies = TRUE)

## Load packages required for AFAM
lapply(list.of.packages, require, character.only = TRUE)

## Install AFAM from Github, an online file-sharing service
devtools::install_github("SFG-UCSB/afamAppPackage")

5.2 Installling the dashboard from a local file on your computer

This is the option to choose if you don’t internet connectivity, but do have a copy of the app file (this will be called something like “afamAppPackage_0.1.tar.gz”). This option will install the AFAM package onto your computer using this file. Note that this may mean you don’t have the most up-to-date version of the app as possible.

If you choose this option, simply copy and paste the following code into your R Studio console and run the code. Note that you’ll need to change the working directory to the location where you have the app file.

## Specify packages that are required for AFAM app. Install them if they're not installed already
list.of.packages <- c("tidyverse", "gridExtra", "pander", "shiny", "DT","devtools","readxl","stringr","LBSPR","TropFishR","lubridate","zoo","curl")
new.packages <- list.of.packages[!(list.of.packages %in% installed.packages()[,"Package"])]
if(length(new.packages) > 0 ) install.packages(new.packages, dependencies = TRUE)

## Load packages required for AFAM
lapply(list.of.packages, require, character.only = TRUE)

## Set your working directory to where the AFAM app file is located. Note that you'll need to change this to match the actual directory on your computer
setwd("/Users/gmcdonald/github/afamAppPackage")
## Install AFAM from your local file
devtools::install.packages("afamAppPackage_0.1.tar.gz",repos=NULL)

5.3 Running the AFAM Toolkit Dashboard (does not require internet)

You now have the AFAM App Package installed on your computer! To use it, simply load the package, and run the app. You may copy and paste the following code into your R Studio console. Note that once the package is installed during the step above, you no longer need internet connectivity to run the app!

## load Shiny package
library(shiny)
## Load AFAM Package
library(afamAppPackage)

## Run AFAM App
runAFAM()

```