Skip to content

Commit

Permalink
removed plotting code from tech doc chapters
Browse files Browse the repository at this point in the history
removed plotting code from tech doc chapters
  • Loading branch information
BBeltz1 committed Feb 13, 2024
1 parent 927bfe8 commit 790eeba
Show file tree
Hide file tree
Showing 69 changed files with 122 additions and 1,035 deletions.
15 changes: 1 addition & 14 deletions chapters/Annual_SST_cycle_indicator.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -23,17 +23,4 @@ Data for annual sea surface tempature (SST) cycles were derived from the NOAA op
### Data extraction
Daily mean sea surface temperature data for 2017 and for each year during the period of 1981-2012 were downloaded from the NOAA [OI SST V2 site](https://www.esrl.noaa.gov/psd/data/gridded/data.noaa.oisst.v2.highres.html) to derive the long-term climatological mean for the period. The use of a 30-year climatological reference period is a standard procedure for metereological observing [@WMO2017]. These reference periods serve as benchmarks for comparing current or recent observations, and for the development of standard anomaly data sets. The reference period of 1982-2012 was chosen to be consistent with previous versions of the State of the Ecosystem report.

R code used in extraction and processing can be found [here](https://github.com/NOAA-EDAB/tech-doc/blob/master/R/stored_scripts/annual_sst_cycles_extraction_and_processing.R).


### Data analysis
We calculated the long-term mean and standard deviation of SST over the period of 1982-2012 for each EPU, as well as the daily mean for 2017.

R code used for analysis and plotting can be found [here](https://github.com/NOAA-EDAB/tech-doc/blob/master/R/stored_scripts/annual_sst_cycles_analysis_and_plotting.R).

```{r , out.width="80%", fig.asp = 0.45, fig.cap = "Long-term mean SSTs for the Mid-Atlantic Bight (A), Georges Bank (B), and Gulf of Maine (C). Orange and cyan shading show where the 2017 daily SST values were above or below the long-term mean respectively; red and dark blue shades indicate days when the 2017 mean exceeded +/- 1 standard deviation from the long-term mean.", echo = F, fig.align="center", eval=T }
knitr::include_graphics(file.path(image.dir, "annual_SST_cycle_plot.png"))
```

R code used in extraction and processing can be found [here](https://github.com/NOAA-EDAB/tech-doc/blob/master/R/stored_scripts/annual_sst_cycles_extraction_and_processing.R).
7 changes: 0 additions & 7 deletions chapters/Aquaculture_indicators.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,6 @@ No further analysis was conducted on these.
Aquaculture data were formatted for inclusion in the `ecodata` R package using the code found [here](https://github.com/NOAA-EDAB/ecodata/blob/master/data-raw/get_aquaculture.R).


### Plotting
Code for plotting data included in the State of the Ecosystem report can be found [here](https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/human_dimensions_MAB.Rmd-aquaculture.R).

```{r, code = readLines("https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/human_dimensions_NE.Rmd-aquaculture-pieces.R"), fig.cap="Total oyster production in peices from areas leased for New England states.",echo = F, eval =T, warning = F, message=F}
```


## Methods 2017-2019
Aquaculture data included in the State of the Ecosystem (SOE) report were time series of number of oysters sold in Virginia, Maryland, and New Jersey.

Expand Down
12 changes: 1 addition & 11 deletions chapters/Bennet_indicator.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,4 @@ Total revenue change between time $t$ and $t+1$ is the sum of the VI and PI. Sin

### Data processing

Bennet indicator time series were formatted for inclusion in the `ecodata` R package using the R code found [here](https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/data-raw/get_bennet.R).


### Plotting
Code for plotting the bennet indicator can be found [here](https://github.com/NOAA-EDAB/ecodata/blob/master/chunk-scripts/human_dimensions.Rmd-bennet.R).

```{r, code = readLines("https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/human_dimensions_MAB.Rmd-bennet.R"), eval=TRUE, echo = FALSE, fig.cap = "Revenue change from the long-term mean in 2015 dollars (black), Price (PI), and Volume Indicators (VI) for commercial landings in the Mid-Atlantic."}
```


Bennet indicator time series were formatted for inclusion in the `ecodata` R package using the R code found [here](https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/data-raw/get_bennet.R).
11 changes: 1 addition & 10 deletions chapters/Catch_and_Fleet_Diversity_indicators.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -57,13 +57,4 @@ for all $k$, where $p_{kt}$ represents the proportion of total revenue generated

### Data processing

Catch and fleet diversity indicators were formatted for inclusion in the `ecodata` R package using the R script found [here](https://github.com/NOAA-EDAB/ecodata/blob/master/data-raw/get_commercial_div.R).

### Plotting

Code for plotting the catch and fleet diversity indicator can be found [here](https://github.com/NOAA-EDAB/ecodata/blob/master/chunk-scripts/human_dimensions.Rmd-comm-div.R).

```{r , code = readLines("https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/human_dimensions_MAB.Rmd-commercial-div.R"), fig.cap = "Fleet diversity and fleet count in the Mid-Atlantic.", fig.align="center", eval=T, echo=F}
```

Catch and fleet diversity indicators were formatted for inclusion in the `ecodata` R package using the R script found [here](https://github.com/NOAA-EDAB/ecodata/blob/master/data-raw/get_commercial_div.R).
127 changes: 59 additions & 68 deletions chapters/Comm_climate_vuln_indicator.Rmd
Original file line number Diff line number Diff line change
@@ -1,68 +1,59 @@
# Fishing Community Climate Vulnerability

**Description**: Community climate vulnerability

**Found in**: State of the Ecosystem - Gulf of Maine & Georges Bank (2018), State of the Ecosystem - Mid-Atlantic (2018)

**Indicator category**: Database pull with analysis

**Contributor(s)**: Lisa L. Colburn

**Data steward**: Lisa L. Colburn, <[email protected]>

**Point of contact**: Lisa L. Colburn, <[email protected]>

**Public availability statement**: The fisheries data used for this analysis includes confidential information and is not available to the public.



## Methods
### Data sources
The data used in community climate vulnerability analyses were derived from the following sources in partnership with the Atlantic Coastal Cooperative Statistics Program's (ACCSP) Standard Atlantic Fisheries Information System (SAFIS).

```{r source table, echo = F, include = T, results='asis'}
tabl <- '
|Database Name | Description |
|:-------------------------|:-------------------------------------|
|Cfdersyyyy|The dealer data are transaction-level pricing at the level of the "market-category." These data are primarily generated through mandatory reporting by federally-permitted fish dealers. The federal reporting is supplemented with data from non-federally-permitted (state-only) fish dealers. Data are currently reported electronically in partnership with ACCSP through SAFIS. |
|Cfvessyyy|A related database that contains permit information. |
'
cat(tabl)
```

In these databases, the variable "port" contains the post associated with the vessel. The variable "Statenm" refers to the state of the mailing address of the owner.

### Data extraction
Code for plotting the community climate vulnerability indicator can be found [here](https://github.com/NOAA-EDAB/tech-doc/tree/master/R/stored_scripts/comm_climate_vuln_extraction.sql).


### Data analysis

The results described below were developed using the methodology described in @colburn_indicators_2016.

1. *Mapping community climate vulnerability* - The map was produced using two variables: total value landed in a community and community species vulnerability, defined below:
a. Communities were grouped based on total value of landings into the following categories: 1 (<\$ 200,000), 2 (\$200,000-\$9,999,999), 3 (\$10,000,000-\$49, 999,999), and 4 (\$50,000,000 and above). Only communities with a total value landed of \$200,000 or more were selected for the mapping process.
b. Community climate vulnerability is determined by the percent contribution of species classified as very high, high, moderate, or low climate vulnerability in a community. The percent contribution of species is calculated as following:


* **% VH & H** = value of landing contributed by species classified as having very high or high climate change vulnerability/total value of landings \* 100

* **% M** = value of landing contributed by species classified as having moderate climate
change vulnerability/total value of landings \* 100

* **% L** = value of landing contributed by species classified as having low climate change
vulnerability/ total value of landings \* 100

If a community received a dominant score (50% or more) for any of the above categories, % VH &, %M, or %L, then the community received a respective community species vulnerability ranking of High, Moderate, or Low. For example, if 90% of the total value landed a community is contributed by species classified as having very high or high climate change vulnerability, then this community gets "Very High/High" community species vulnerability. In case of no dominant percentage identified, the community gets a "Mixed" community species vulnerability ranking.

2) *Pie charts* - The pie charts were created using the National Marine Fisheries Service (NMFS) landings data pulled from New England Fisheries Science Center (NEFSC) databases in Woods Hole, MA. The percent contribution of each species was calculated by dividing the total value of landings in each port by each species' landed value. Data was calculated and graphed in a pie chart in Excel and given the colors that represent High (red), Moderate (blue), Low (yellow) climate vulnerability. The "other" category consists of species with low landings and/or those that do not have a vulnerability ranking based on @Hare2016. These species were aggregated and given the color gray.

### Plotting

```{r species-vulnerability, fig.cap="Commercial species vulnerability to climate change in in New England fishing communities.",fig.align = 'center', echo = F, eval = T, out.width='80%'}
knitr::include_graphics(file.path(image.dir, 'Species_vulnerability_NE.JPG'))
```



# Fishing Community Climate Vulnerability

**Description**: Community climate vulnerability

**Found in**: State of the Ecosystem - Gulf of Maine & Georges Bank (2018), State of the Ecosystem - Mid-Atlantic (2018)

**Indicator category**: Database pull with analysis

**Contributor(s)**: Lisa L. Colburn

**Data steward**: Lisa L. Colburn, <[email protected]>

**Point of contact**: Lisa L. Colburn, <[email protected]>

**Public availability statement**: The fisheries data used for this analysis includes confidential information and is not available to the public.



## Methods
### Data sources
The data used in community climate vulnerability analyses were derived from the following sources in partnership with the Atlantic Coastal Cooperative Statistics Program's (ACCSP) Standard Atlantic Fisheries Information System (SAFIS).

```{r source table, echo = F, include = T, results='asis'}
tabl <- '
|Database Name | Description |
|:-------------------------|:-------------------------------------|
|Cfdersyyyy|The dealer data are transaction-level pricing at the level of the "market-category." These data are primarily generated through mandatory reporting by federally-permitted fish dealers. The federal reporting is supplemented with data from non-federally-permitted (state-only) fish dealers. Data are currently reported electronically in partnership with ACCSP through SAFIS. |
|Cfvessyyy|A related database that contains permit information. |
'
cat(tabl)
```

In these databases, the variable "port" contains the post associated with the vessel. The variable "Statenm" refers to the state of the mailing address of the owner.

### Data extraction
Code for plotting the community climate vulnerability indicator can be found [here](https://github.com/NOAA-EDAB/tech-doc/tree/master/R/stored_scripts/comm_climate_vuln_extraction.sql).


### Data analysis

The results described below were developed using the methodology described in @colburn_indicators_2016.

1. *Mapping community climate vulnerability* - The map was produced using two variables: total value landed in a community and community species vulnerability, defined below:
a. Communities were grouped based on total value of landings into the following categories: 1 (<\$ 200,000), 2 (\$200,000-\$9,999,999), 3 (\$10,000,000-\$49, 999,999), and 4 (\$50,000,000 and above). Only communities with a total value landed of \$200,000 or more were selected for the mapping process.
b. Community climate vulnerability is determined by the percent contribution of species classified as very high, high, moderate, or low climate vulnerability in a community. The percent contribution of species is calculated as following:


* **% VH & H** = value of landing contributed by species classified as having very high or high climate change vulnerability/total value of landings \* 100

* **% M** = value of landing contributed by species classified as having moderate climate
change vulnerability/total value of landings \* 100

* **% L** = value of landing contributed by species classified as having low climate change
vulnerability/ total value of landings \* 100

If a community received a dominant score (50% or more) for any of the above categories, % VH &, %M, or %L, then the community received a respective community species vulnerability ranking of High, Moderate, or Low. For example, if 90% of the total value landed a community is contributed by species classified as having very high or high climate change vulnerability, then this community gets "Very High/High" community species vulnerability. In case of no dominant percentage identified, the community gets a "Mixed" community species vulnerability ranking.

2) *Pie charts* - The pie charts were created using the National Marine Fisheries Service (NMFS) landings data pulled from New England Fisheries Science Center (NEFSC) databases in Woods Hole, MA. The percent contribution of each species was calculated by dividing the total value of landings in each port by each species' landed value. Data was calculated and graphed in a pie chart in Excel and given the colors that represent High (red), Moderate (blue), Low (yellow) climate vulnerability. The "other" category consists of species with low landings and/or those that do not have a vulnerability ranking based on @Hare2016. These species were aggregated and given the color gray.
31 changes: 1 addition & 30 deletions chapters/Comm_rel_vuln_indicator.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -34,33 +34,4 @@ The indicators were developed using the methodology described in @Jacob2010, @Ja

### Data processing

Data were formatted for inclusion in the ecodata R package using the R script found [here](https://github.com/NOAA-EDAB/ecodata/blob/master/data-raw/get_engagement.R).


### Plotting

Code used to build the community engagement indicator plot below can be found [here](https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/human_dimensions_MAB.Rmd-commercial-engagement.R).


```{r , code = readLines("https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/human_dimensions_MAB.Rmd-commercial-engagement.R"), eval = T, fig.cap= "Commercial engagement, reliance and environmental justice vulnerability for thetop commercial fishing communities in the Mid-Atlantic. (* Scored high (1.00 and above)) for both commercial engagement and reliance indicators)."}
```

```{r , fig.cap = "Environmental justice indicators (Poverty index, population composition index, and personal disruption index) for top commercial fishing communities in the Mid-Atlantic.", out.width="90%"}
knitr::include_graphics(c(file.path(image.dir, "EJ_Commercial_MAB_2023.PNG")))
```


```{r , code = readLines("https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/human_dimensions_MAB.Rmd-recreational-engagement.R"), eval = T, fig.cap= "Recreational engagement, reliance and environmental justice vulnerability for the top recreational fishing communities in the Mid-Atlantic. (* Scored high (1.00 and above)) for both recreational engagement and reliance indicators)."}
```

```{r , fig.cap = "Environmental justice indicators (Poverty index, population composition index, and personal disruption index) for top recreational fishing communities in the Mid-Atlantic.", out.width="90%"}
knitr::include_graphics(c(file.path(image.dir, "EJ_Recreational_MAB_2023.PNG")))
```


Data were formatted for inclusion in the ecodata R package using the R script found [here](https://github.com/NOAA-EDAB/ecodata/blob/master/data-raw/get_engagement.R).
13 changes: 1 addition & 12 deletions chapters/Condition_indicator.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,4 @@ $$\textrm{Weight} = e^{Fall_{coef}} * \textrm{Length}^{Fall_{exp}},$$
where $Fall coef$ and $Fall exp$ are from @Wigley2003.


The code found [here](https://github.com/Laurels1/Condition/blob/master/R/RelConditionEPU.R) was used in the analysis of fish condition.


### Plotting
Code for plotting the fish condition indicator can be found [here](https://github.com/Laurels1/Condition/blob/master/R/Condition_plot_viridis_final.R).

```{r, fig.cap=" Condition factor for fish species in the MAB. MAB data are missing for 2017 due to survey delays and for 2020 due to Covid."}
image.dir <- here::here("images")
knitr::include_graphics(file.path(image.dir, "MAB_Condition_allsex_2023_viridis.jpg"))
```
The code found [here](https://github.com/Laurels1/Condition/blob/master/R/RelConditionEPU.R) was used in the analysis of fish condition.
13 changes: 1 addition & 12 deletions chapters/Expected_Number.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,4 @@ The number of species represented in these samples of 1000 fishes are then avera


### Data processing
Data were formatted for inclusion in the `ecodata` R package using the R code found [here](https://github.com/NOAA-EDAB/ecodata/blob/master/data-raw/get_exp_n.R).

### Plotting

The plot below was built using the code found
[here](https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/macrofauna_MAB.Rmd-exp-n.R).

```{r, code = readLines("https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/macrofauna_MAB.Rmd-exp-n.R"), eval = T, echo = F, fig.cap = "Expected number of species per 1000 individuals for in the Mid-Atlantic Bight from the Fall NEFSC bottom trawl survey."}
```


Data were formatted for inclusion in the `ecodata` R package using the R code found [here](https://github.com/NOAA-EDAB/ecodata/blob/master/data-raw/get_exp_n.R).
15 changes: 1 addition & 14 deletions chapters/Forage_Fish_Biomass_Index.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -66,17 +66,4 @@ Spring, fall, and annual prey indices were developed for the full VAST extrapola

Full VAST model results for Fall, Spring, and Annual models, along with diagnostics, are available at [this link](https://sgaichas.github.io/bluefishdiet/VASTcovariates_forageindex_WP.html).

Code used to develop this indicator from the full set of VAST model index outputs is [available here](https://github.com/NOAA-EDAB/tech-doc/blob/master/R/stored_scripts/SOE-VASTForageIndices.R).


### Plotting
Code use to build the plots below can be found here - [MAB](https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/macrofauna_MAB.Rmd-forage-index.R) and [NE](https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/macrofauna_NE.Rmd-forage-index.R).

```{r , code = readLines("https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/macrofauna_MAB.Rmd-forage-index.R"), eval = T, echo=F, fig.cap="Mid-Atlantic Bight forage biomass index."}
```


```{r , code = readLines("https://raw.githubusercontent.com/NOAA-EDAB/ecodata/master/chunk-scripts/macrofauna_NE.Rmd-forage-index.R"), eval = T, echo=F, fig.cap="Georges Bank and Gulf of Maine forage biomass index."}
```
Code used to develop this indicator from the full set of VAST model index outputs is [available here](https://github.com/NOAA-EDAB/tech-doc/blob/master/R/stored_scripts/SOE-VASTForageIndices.R).
Loading

0 comments on commit 790eeba

Please sign in to comment.