r3PG
An R package for forest growth simulation using the 3-PG process-based model
Science Score: 39.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
✓DOI references
Found 12 DOI reference(s) in README -
○Academic publication links
-
○Committers with academic emails
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (15.2%) to scientific vocabulary
Repository
An R package for forest growth simulation using the 3-PG process-based model
Basic Info
- Host: GitHub
- Owner: trotsiuk
- License: gpl-3.0
- Language: HTML
- Default Branch: master
- Homepage: https://trotsiuk.github.io/r3PG/
- Size: 272 MB
Statistics
- Stars: 29
- Watchers: 4
- Forks: 17
- Open Issues: 3
- Releases: 7
Metadata Files
README.md
Purpose
r3PG provides an implementation of the Physiological Processes Predicting Growth (3-PG) model (Landsberg & Waring, 1997), which simulate forest growth and productivity. The r3PG serves as a flexible and easy-to-use interface for the 3-PGpjs (Sands, 2010) and the 3-PGmix (Forrester & Tang, 2016) model written in Fortran. The package enables fast and easy interaction with the model, and the Fortran re-implementation facilitates computationally intensive sensitivity analysis and calibration. The user can flexibly switch between various options and submodules, to use the original 3-PGpjs model version for monospecific, even-aged and evergreen forests and the 3-PGmix model, which can also simulate multi-cohort stands (e.g. mixtures, uneven-aged) that contain deciduous species.
Usage
Below is a basic example, for more extended examples please visit package vignette.
The main function is run_3PG() which returns all 108 simulated variables for each species at a monthly time-step, either as a 4-dimentional array or a long format data frame.
```r library(r3PG) out3PG <- run3PG( site = dsite, species = dspecies, climate = dclimate, thinning = dthinning, parameters = dparameters, sizedist = dsizeDist, settings = list(lightmodel = 2, transpmodel = 2, physmodel = 2, heightmodel = 1, correctbias = 0, calculated13c = 0), checkinput = TRUE, df_out = TRUE)
head( out_3PG ) ```
To visualize the output: ``` r library(dplyr) library(ggplot2)
selvar <- c('biomstem', 'biomfoliage', 'biomroot')
out3PG %>% filter( variable %in% selvar ) %>% ggplot( aes(date, value, color = species) ) + geomline() + facetwrap(~variable, scales = 'free') + theme_classic() ```
If you prefer to use data stored in Excell, you can use the following example. Data to reproduce this example are stored in data-raw/internal_data/data.input.xlsx.
``` r library(readxl)
f_loc <- 'data.input.xlsx'
run3PG( site = readxlsx(floc, 'site'), species = readxlsx(floc, 'species'), climate = readxlsx(floc, 'climate'), thinning = readxlsx(floc, 'thinning'), parameters = readxlsx(floc, 'parameters'), sizedist = readxlsx(floc, 'sizeDist'), settings = list(lightmodel = 2, transpmodel = 2, physmodel = 2, heightmodel = 1, correctbias = 0, calculated13c = 0), checkinput = TRUE, dfout = TRUE) ```
Installation
Stable release
r3PG is available for instalation from CRAN
r
install.packages("r3PG")
Development release
To install the current (development) version from the repository, run the following command:
r
if(!require(devtools)){install.packages(devtools)}
devtools::install_github(repo = "trotsiuk/r3PG", build_vignettes = T)
The unit test status of the master (development) branch is
Other 3-PG implementations in R
We would like to acknowledge that r3PG is not the only 3-PG implementations in R. We are aware of the following other packages:
| Maintainer | Source | | ------------------- | ------ | | Daniel M. Griffith | https://github.com/griffithdan/r3PG | | Georgios Xenakis | https://github.com/drGeorgeXenakis/fr3PGD | | Francesco Minunno | https://github.com/checcomi/threePGN-package | | Quinn Thomas | https://github.com/EcoDynForecast/DAPPER |
We explain in a recent publication (Trotsiuk et al, 2020) how these r3PG packages differs and / or improves over these.
Issues, suggestions, contributions
Please submit issues, bugs and suggestions in the dedicated page. Contribution and improvements are always welcome!
Author and contact
Volodymyr Trotsiuk; Florian Hartig; David I. Forrester
Citation
Trotsiuk, V., Hartig, F., Forrester, D.I. (2020). r3PG – an R package for simulating forest growth using the 3-PG process-based model. Methods Ecol. Evol., 11, 1470–1475. https://doi.org/10.1111/2041-210X.13474
References
Forrester, D. I., & Tang, X. (2016). Analysing the spatial and temporal dynamics of species interactions in mixed-species forests and the effects of stand density using the 3-PG model. Ecological Modelling, 319, 233–254. https://doi.org/10.1016/j.ecolmodel.2015.07.010
Landsberg, J. J., & Waring, R. H. (1997). A generalised model of forest productivity using simplified concepts of radiation-use efficiency, carbon balance and partitioning. Forest Ecology and Management, 95(3), 209–228. https://doi.org/10.1016/S0378-1127(97)00026-1
Sands, P. J. (2010). 3PGpjs user manual. Retrieved from https://3pg.sites.olt.ubc.ca/files/2014/04/3PGpjs_UserManual.pdf
Trotsiuk, V., Hartig, F., Cailleret, M., Babst, F., Forrester, D. I., Baltensweiler, A., … Schaub, M. (2020). Assessing the response of forest productivity to climate extremes in Switzerland using model–data fusion. Global Change Biology, 26(4), 2463–2476. https://doi.org/10.1111/gcb.15011
Forrester, D. I., Hobi M. L., Mathys A. S., Stadelmann G., Trotsiuk V. (2021). Calibration of the process-based model 3-PG for major central European tree species. European Journal of Forest Research, 140, 847-868. https://doi.org/10.1007/s10342-021-01370-3
Owner
- Name: Trotsiuk Volodymyr
- Login: trotsiuk
- Kind: user
- Location: Birmensdorf
- Company: Swiss Federal Research Institute WSL
- Website: https://www.wsl.ch/en/employees/trotsiuk.html
- Twitter: trotsiukv
- Repositories: 1
- Profile: https://github.com/trotsiuk
RESEARCHER and DATA SCIENTIST
GitHub Events
Total
- Issues event: 3
- Watch event: 2
- Issue comment event: 8
- Push event: 20
- Create event: 4
Last Year
- Issues event: 3
- Watch event: 2
- Issue comment event: 8
- Push event: 20
- Create event: 4
Committers
Last synced: 11 months ago
Top Committers
| Name | Commits | |
|---|---|---|
| trotsiuk | v****k@g****m | 115 |
| Volodymyr Trotsiuk | v****k@w****h | 54 |
| florianhartig | f****g | 28 |
| Rasilgon | r****n@g****m | 11 |
| trotsiuk | t****k@r****h | 2 |
| trotsiuk | t****k@r****l | 1 |
Committer Domains (Top 20 + Academic)
Issues and Pull Requests
Last synced: 10 months ago
All Time
- Total issues: 83
- Total pull requests: 21
- Average time to close issues: 4 months
- Average time to close pull requests: about 1 month
- Total issue authors: 16
- Total pull request authors: 4
- Average comments per issue: 4.04
- Average comments per pull request: 0.29
- Merged pull requests: 18
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 3
- Pull requests: 0
- Average time to close issues: 6 months
- Average time to close pull requests: N/A
- Issue authors: 2
- Pull request authors: 0
- Average comments per issue: 0.0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- florianhartig (25)
- trotsiuk (23)
- twest820 (9)
- DavidForrester (6)
- Rasilgon (6)
- SebastianBr2 (3)
- GakenouOF (2)
- LisaHuelsmann (1)
- ChaitraliGore (1)
- Catarinaxa (1)
- Alvertin83 (1)
- JohannesOberpriller (1)
- zhengjiji456 (1)
- jm5233 (1)
- issamyax (1)
Pull Request Authors
- trotsiuk (13)
- Rasilgon (5)
- florianhartig (2)
- JohannesOberpriller (1)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 1
-
Total downloads:
- cran 197 last-month
- Total docker downloads: 7
- Total dependent packages: 0
- Total dependent repositories: 0
- Total versions: 7
- Total maintainers: 1
cran.r-project.org: r3PG
Simulating Forest Growth using the 3-PG Model
- Homepage: https://github.com/trotsiuk/r3PG
- Documentation: http://cran.r-project.org/web/packages/r3PG/r3PG.pdf
- License: GPL-3
-
Latest release: 0.1.6
published almost 3 years ago
Rankings
Maintainers (1)
Dependencies
- actions/checkout v3 composite
- r-lib/actions/check-r-package v2 composite
- r-lib/actions/setup-pandoc v2 composite
- r-lib/actions/setup-r v2 composite
- r-lib/actions/setup-r-dependencies v2 composite
- R >= 3.5.0 depends
- BayesianTools * suggests
- R.rsp >= 0.40.0 suggests
- dplyr * suggests
- ggplot2 * suggests
- knitr >= 1.15.1 suggests
- rmarkdown >= 1.3 suggests
- roxygen2 * suggests
- sensitivity * suggests
- testthat >= 1.0.2 suggests