Last updated: 2020-11-06
Checks: 7 0
Knit directory: BloomSail/
This reproducible R Markdown analysis was created with workflowr (version 1.6.2). The Checks tab describes the reproducibility checks that were applied when the results were created. The Past versions tab lists the development history.
Great! Since the R Markdown file has been committed to the Git repository, you know the exact version of the code that produced these results.
Great job! The global environment was empty. Objects defined in the global environment can affect the analysis in your R Markdown file in unknown ways. For reproduciblity it’s best to always run the code in an empty environment.
The command set.seed(20191021)
was run prior to running the code in the R Markdown file. Setting a seed ensures that any results that rely on randomness, e.g. subsampling or permutations, are reproducible.
Great job! Recording the operating system, R version, and package versions is critical for reproducibility.
Nice! There were no cached chunks for this analysis, so you can be confident that you successfully produced the results during this run.
Great job! Using relative paths to the files within your workflowr project makes it easier to run your code on other machines.
Great! You are using Git for version control. Tracking code development and connecting the code version to the results is critical for reproducibility.
The results in this page were generated with repository version bf70fd5. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.
Note that you need to be careful to ensure that all relevant files for the analysis have been committed to Git prior to generating the results (you can use wflow_publish
or wflow_git_commit
). workflowr only checks the R Markdown file, but you know if there are other scripts or data files that it depends on. Below is the status of the Git repository when the results were generated:
Ignored files:
Ignored: .Rhistory
Ignored: .Rproj.user/
Ignored: data/input/
Ignored: data/intermediate/
Ignored: data/output_submission/
Untracked files:
Untracked: output/Plots/Figures_publication/
Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.
These are the previous versions of the repository in which changes were made to the R Markdown (analysis/Phytoplankton.Rmd
) and HTML (docs/Phytoplankton.html
) files. If you’ve configured a remote Git repository (see ?wflow_git_remote
), click on the hyperlinks in the table below to view the files as they were in that past version.
File | Version | Author | Date | Message |
---|---|---|---|---|
Rmd | bf70fd5 | jens-daniel-mueller | 2020-11-06 | removed sec axis with moles-C unit |
html | 7e29c30 | jens-daniel-mueller | 2020-11-02 | Build site. |
Rmd | 7e5a700 | jens-daniel-mueller | 2020-11-02 | renamed and revised figures for publication |
html | e9306ef | jens-daniel-mueller | 2020-10-26 | Build site. |
Rmd | 1b371ec | jens-daniel-mueller | 2020-10-26 | included total biomass |
html | 9a3f42a | jens-daniel-mueller | 2020-10-24 | Build site. |
Rmd | 766a349 | jens-daniel-mueller | 2020-10-24 | biomass unit conversion |
html | b289357 | jens-daniel-mueller | 2020-10-24 | Build site. |
Rmd | 576f7f9 | jens-daniel-mueller | 2020-10-24 | unit conversion biomass |
html | dd00fd3 | jens-daniel-mueller | 2020-10-24 | Build site. |
Rmd | 58406a9 | jens-daniel-mueller | 2020-10-24 | unit conversion biomass |
html | c9a2935 | jens-daniel-mueller | 2020-10-24 | Build site. |
Rmd | 5fd3472 | jens-daniel-mueller | 2020-10-24 | unit conversion biomass |
html | 05248bf | jens-daniel-mueller | 2020-10-20 | Build site. |
html | 1c4fe8e | jens-daniel-mueller | 2020-10-20 | table with time series in depth intervals added |
html | 6896725 | jens-daniel-mueller | 2020-10-01 | Build site. |
html | 9f66019 | jens-daniel-mueller | 2020-10-01 | Build site. |
html | 27c5431 | jens-daniel-mueller | 2020-09-29 | Build site. |
Rmd | 2e0f902 | jens-daniel-mueller | 2020-09-29 | all parameters separate, rebuild |
html | 1d01685 | jens-daniel-mueller | 2020-09-28 | Build site. |
html | 1278900 | jens-daniel-mueller | 2020-09-25 | Build site. |
html | 904f0f7 | jens-daniel-mueller | 2020-09-23 | Build site. |
html | c919fb7 | jens-daniel-mueller | 2020-06-29 | Build site. |
Rmd | 1461cb6 | jens-daniel-mueller | 2020-06-29 | Fig update for talk |
html | 603af23 | jens-daniel-mueller | 2020-05-25 | Build site. |
html | 3414c23 | jens-daniel-mueller | 2020-05-25 | Build site. |
html | 9ccd9a3 | jens-daniel-mueller | 2020-05-25 | Build site. |
Rmd | 9bedac5 | jens-daniel-mueller | 2020-05-25 | revised pp time series plot |
html | ae61e7e | jens-daniel-mueller | 2020-05-25 | Build site. |
Rmd | 3080fb3 | jens-daniel-mueller | 2020-05-25 | Added Phytoplanktion read-in and new Rmd |
library(tidyverse)
tp <- read_csv(
here::here("data/intermediate/_summarized_data_files",
"tp.csv"),
col_types = cols(ID = col_character())
)
cruise_dates <-
read_csv(
here::here(
"data/intermediate/_summarized_data_files",
"cruise_date.csv"
),
col_types = cols(ID = col_character())
)
#### calculate mean total phytoplanton biomass in different water depth intervals
tp <- tp %>%
filter(
station %in% parameters$stations_in_phytoplankton,
class == parameters$class_in_phytoplankton,
Species != "Nodulariadead"
) %>%
mutate(ID = if_else(ID == "180722", "180723", ID))
tp <- tp %>%
mutate(dep_grid = cut(
dep,
breaks = c(-1, parameters$surface_dep, parameters$max_dep),
labels = c("0-6", "6-25")
)) %>%
drop_na()
tp_ID_grid <- tp %>%
group_by(ID, dep_grid, Species) %>%
summarise(value = mean(value, na.rm = TRUE)) %>%
ungroup()
tp_ID_grid <- full_join(cruise_dates, tp_ID_grid)
tp_ID_grid <- tp_ID_grid
tp_ID_grid %>%
filter(Species != "total") %>%
ggplot(aes(date_time_ID, value, col = dep_grid)) +
geom_point() +
geom_line() +
facet_wrap(~ Species, ncol=1) +
scale_color_brewer(palette = "Set1", name = "Depth (m)") +
scale_x_datetime(breaks = "week", date_labels = "%d %b") +
# scale_y_continuous(sec.axis = sec_axis(~ . * 0.16 / 12,
# name = expression(Biomass ~ (mu~mol-C~kg^-1)))) +
labs(y = expression(Biomass ~ (mg~m^-3))) +
theme(axis.title.x = element_blank())
ggsave(
here::here(
"output/Plots/Figures_publication/appendix",
"Fig_S5.pdf"
),
width = 180,
height = 120,
dpi = 300,
units = "mm"
)
ggsave(
here::here(
"output/Plots/Figures_publication/appendix",
"Fig_S5.png"
),
width = 180,
height = 120,
dpi = 300,
units = "mm"
)
sessionInfo()
R version 4.0.2 (2020-06-22)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 18363)
Matrix products: default
locale:
[1] LC_COLLATE=English_Germany.1252 LC_CTYPE=English_Germany.1252
[3] LC_MONETARY=English_Germany.1252 LC_NUMERIC=C
[5] LC_TIME=English_Germany.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] forcats_0.5.0 stringr_1.4.0 dplyr_1.0.0 purrr_0.3.4
[5] readr_1.3.1 tidyr_1.1.0 tibble_3.0.3 ggplot2_3.3.2
[9] tidyverse_1.3.0 workflowr_1.6.2
loaded via a namespace (and not attached):
[1] tidyselect_1.1.0 xfun_0.16 haven_2.3.1 colorspace_1.4-1
[5] vctrs_0.3.2 generics_0.0.2 htmltools_0.5.0 yaml_2.2.1
[9] blob_1.2.1 rlang_0.4.7 later_1.1.0.1 pillar_1.4.6
[13] withr_2.2.0 glue_1.4.1 DBI_1.1.0 RColorBrewer_1.1-2
[17] dbplyr_1.4.4 modelr_0.1.8 readxl_1.3.1 lifecycle_0.2.0
[21] munsell_0.5.0 gtable_0.3.0 cellranger_1.1.0 rvest_0.3.6
[25] evaluate_0.14 labeling_0.3 knitr_1.30 httpuv_1.5.4
[29] fansi_0.4.1 broom_0.7.0 Rcpp_1.0.5 promises_1.1.1
[33] backports_1.1.8 scales_1.1.1 jsonlite_1.7.0 farver_2.0.3
[37] fs_1.4.2 hms_0.5.3 digest_0.6.25 stringi_1.4.6
[41] rprojroot_1.3-2 grid_4.0.2 here_0.1 cli_2.0.2
[45] tools_4.0.2 magrittr_1.5 crayon_1.3.4 whisker_0.4
[49] pkgconfig_2.0.3 ellipsis_0.3.1 xml2_1.3.2 reprex_0.3.0
[53] lubridate_1.7.9 assertthat_0.2.1 rmarkdown_2.3 httr_1.4.2
[57] rstudioapi_0.11 R6_2.4.1 git2r_0.27.1 compiler_4.0.2