Skip to content
Snippets Groups Projects
Commit 55bd55b3 authored by clblatte's avatar clblatte
Browse files

expand quick_summary.Rmd

parent 86bd7ca1
No related branches found
No related tags found
No related merge requests found
......@@ -14,7 +14,7 @@ knitr::opts_chunk$set(echo = TRUE)
```{r, include=FALSE}
path <- paste0(getwd(),"/")
source(paste0(path,"main.R"))
source(paste0(path,"Main.R"))
library(tidyr)
library(dplyr)
......@@ -57,9 +57,10 @@ stands <- rslt %>%
kable(stands) %>% kable_styling()
```
### Development of average stand volume (m3/ha) for certain regimes
### Development of average stand volume V (m3/ha)
#### for certain regimes
```{r}
meanV <- rslt[rslt$regime %in% c("BAU", "SA", "CCF_1") , ] %>%
meanV <- rslt[rslt$regime %in% c("BAU", "SA", "CCF_2", "BAUwGTR"), ] %>%
group_by(year, regime, gpkg) %>%
summarise(meanV = mean(V)) %>%
ggplot(aes(year, meanV)) +
......@@ -70,13 +71,77 @@ meanV <- rslt[rslt$regime %in% c("BAU", "SA", "CCF_1") , ] %>%
facet_wrap(. ~gpkg)
plot(meanV)
```
```
#### only for CCF regimes
```{r}
meanV_CCF <- rslt[rslt$regime %in% c("CCF_1", "CCF_2", "CCF_3", "CCF_4"), ] %>%
group_by(year, regime, gpkg) %>%
summarise(meanV = mean(V)) %>%
ggplot(aes(year, meanV)) +
geom_line( aes(color = regime)) +
theme(axis.text.x = element_text(angle = 90)) +
scale_x_continuous(breaks=c(2016, 2026, 2036, 2046, 2056, 2066, 2076, 2086, 2096, 2106)) +
scale_y_continuous(limit = c(0,700)) +
facet_wrap(. ~gpkg)
plot(meanV_CCF)
```
### Development of average V_total_deadwood (m3/ha) for certain regimes
```{r}
meanDW <- rslt[rslt$regime %in% c("BAU", "SA", "CCF_2", "BAUwGTR") , ] %>%
group_by(year, regime, gpkg) %>%
summarise(mean_DW = mean(V_total_deadwood)) %>%
ggplot(aes(year, mean_DW)) +
geom_line( aes(color = regime)) +
theme(axis.text.x = element_text(angle = 90)) +
scale_x_continuous(breaks=c(2016, 2026, 2036, 2046, 2056, 2066, 2076, 2086, 2096, 2106)) +
facet_wrap(. ~gpkg)
plot(meanDW)
```
### Development of average CARBON_STORAGE (kg/ha) for certain regimes
```{r}
meanCS <- rslt[rslt$regime %in% c("BAU", "SA", "CCF_2", "BAUwGTR") , ] %>%
group_by(year, regime, gpkg) %>%
summarise(mean_CS = mean(CARBON_STORAGE, na.rm = TRUE )/1000) %>%
ggplot(aes(year, mean_CS)) +
geom_line( aes(color = regime)) +
theme(axis.text.x = element_text(angle = 90)) +
scale_x_continuous(breaks=c(2016, 2026, 2036, 2046, 2056, 2066, 2076, 2086, 2096, 2106)) +
facet_wrap(. ~gpkg)
plot(meanCS)
```
### Average harvested timber volume (m3/ha) for certain regimes
Cash flow = The sum of all revenues and costs for a specific forest stand
```{r}
meanHarvested_V <- rslt[rslt$regime %in%c("BAU", "SA", "CCF_2", "BAUwGTR") , ] %>%
group_by(year, regime, gpkg) %>%
mutate(Harvested_V = ifelse(is.na(Harvested_V), 0, Harvested_V)) %>%
summarise(meanHarvested_V = mean(Harvested_V), na.rm = TRUE) %>%
ggplot(aes(year, meanHarvested_V)) +
geom_line( aes(color = regime)) +
theme(axis.text.x = element_text(angle = 90)) +
scale_x_continuous(breaks=c(2016, 2026, 2036, 2046, 2056, 2066, 2076, 2086, 2096, 2106)) +
facet_wrap(. ~gpkg)
plot(meanHarvested_V)
```
### Average cash flow (Euro/ha) for certain regimes
Cash flow = The sum of all revenues and costs for a specific forest stand
```{r}
meanCash <- rslt[rslt$regime %in% c("BAU", "SA", "CCF_1") , ] %>%
meanCash <- rslt[rslt$regime %in%c("BAU", "SA", "CCF_2", "BAUwGTR") , ] %>%
group_by(year, regime, gpkg) %>%
mutate(cash_flow = ifelse(is.na(cash_flow), 0, cash_flow)) %>%
summarise(meanCash = mean(cash_flow), na.rm = TRUE) %>%
......
Source diff could not be displayed: it is too large. Options to address this: view the blob.
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment